diff --git a/.buildkite/pipelines/artifacts.yml b/.buildkite/pipelines/artifacts.yml
index 8e08c736694e8..b6d3cc9fc9b14 100644
--- a/.buildkite/pipelines/artifacts.yml
+++ b/.buildkite/pipelines/artifacts.yml
@@ -73,13 +73,23 @@ steps:
- command: .buildkite/scripts/steps/artifacts/cloud.sh
label: 'Cloud Deployment'
- soft_fail: true
+ soft_fail:
+ - exit_status: 255
agents:
queue: n2-2
timeout_in_minutes: 30
if: "build.env('RELEASE_BUILD') == null || build.env('RELEASE_BUILD') == '' || build.env('RELEASE_BUILD') == 'false'"
retry:
automatic:
+ # Timeout and graceful shutdown | ecctl deployment create falure
+ - exit_status: 255
+ limit: 0
+
+ # Timeout and forced shutdown
+ - exit_status: '-1'
+ limit: 0
+
+ # Test failures
- exit_status: '*'
limit: 1
diff --git a/.buildkite/scripts/steps/artifacts/cloud.sh b/.buildkite/scripts/steps/artifacts/cloud.sh
index 5bf2285ab162a..4d2317ce0b6c7 100644
--- a/.buildkite/scripts/steps/artifacts/cloud.sh
+++ b/.buildkite/scripts/steps/artifacts/cloud.sh
@@ -12,28 +12,28 @@ mkdir -p target
download_artifact "kibana-$FULL_VERSION-linux-x86_64.tar.gz" ./target --build "${KIBANA_BUILD_ID:-$BUILDKITE_BUILD_ID}"
-node scripts/build \
- --skip-initialize \
- --skip-generic-folders \
- --skip-platform-folders \
- --skip-archives \
- --docker-images \
- --skip-docker-ubi \
- --skip-docker-ubuntu \
- --skip-docker-contexts
-
-docker load --input target/kibana-cloud-$FULL_VERSION-docker-image.tar.gz
-
TAG="$FULL_VERSION-$GIT_COMMIT"
-KIBANA_BASE_IMAGE="docker.elastic.co/kibana-ci/kibana-cloud:$FULL_VERSION"
KIBANA_TEST_IMAGE="docker.elastic.co/kibana-ci/kibana-cloud:$TAG"
-docker tag "$KIBANA_BASE_IMAGE" "$KIBANA_TEST_IMAGE"
-
echo "$KIBANA_DOCKER_PASSWORD" | docker login -u "$KIBANA_DOCKER_USERNAME" --password-stdin docker.elastic.co
trap 'docker logout docker.elastic.co' EXIT
-docker push "$KIBANA_TEST_IMAGE"
+if docker manifest inspect $KIBANA_TEST_IMAGE &> /dev/null; then
+ echo "Distribution already exists, skipping build"
+else
+ node scripts/build \
+ --skip-initialize \
+ --skip-generic-folders \
+ --skip-platform-folders \
+ --skip-archives \
+ --docker-images \
+ --docker-tag-qualifier="$GIT_COMMIT" \
+ --docker-push \
+ --skip-docker-ubi \
+ --skip-docker-ubuntu \
+ --skip-docker-contexts
+fi
+
docker logout docker.elastic.co
echo "--- Create deployment"
@@ -62,6 +62,7 @@ function shutdown {
trap "shutdown" EXIT
ecctl deployment create --track --output json --file "$DEPLOYMENT_SPEC" > "$LOGS"
+
CLOUD_DEPLOYMENT_USERNAME=$(jq -r --slurp '.[]|select(.resources).resources[] | select(.credentials).credentials.username' "$LOGS")
CLOUD_DEPLOYMENT_PASSWORD=$(jq -r --slurp '.[]|select(.resources).resources[] | select(.credentials).credentials.password' "$LOGS")
CLOUD_DEPLOYMENT_ID=$(jq -r --slurp '.[0].id' "$LOGS")
diff --git a/.github/CODEOWNERS b/.github/CODEOWNERS
index ea68df6a8bd8c..71af2a3e67230 100644
--- a/.github/CODEOWNERS
+++ b/.github/CODEOWNERS
@@ -194,6 +194,7 @@ x-pack/examples/files_example @elastic/kibana-app-services
# Machine Learning
/x-pack/plugins/ml/ @elastic/ml-ui
+/x-pack/plugins/ml/common/openapi/ @elastic/mlr-docs
/x-pack/test/accessibility/apps/ml.ts @elastic/ml-ui
/x-pack/test/accessibility/apps/ml_embeddables_in_dashboard.ts @elastic/ml-ui
/x-pack/test/api_integration/apis/ml/ @elastic/ml-ui
diff --git a/api_docs/actions.mdx b/api_docs/actions.mdx
index 0e3c26c64fa6b..56520b0ab6d03 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: 2022-09-06
+date: 2022-09-07
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 44f6e2ebbb5c3..7ce9f03610600 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: 2022-09-06
+date: 2022-09-07
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 082d6130630c3..86745b348b398 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: 2022-09-06
+date: 2022-09-07
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 a71cca2e3d278..851021c210af7 100644
--- a/api_docs/alerting.devdocs.json
+++ b/api_docs/alerting.devdocs.json
@@ -1827,7 +1827,7 @@
"section": "def-server.RuleExecutorServices",
"text": "RuleExecutorServices"
},
- ""
+ ""
],
"path": "x-pack/plugins/alerting/server/types.ts",
"deprecated": false,
@@ -1899,22 +1899,14 @@
{
"parentPluginId": "alerting",
"id": "def-server.RuleExecutorServices.alertFactory",
- "type": "Object",
+ "type": "CompoundType",
"tags": [],
"label": "alertFactory",
"description": [],
"signature": [
- "{ create: (id: string) => ",
- {
- "pluginId": "alerting",
- "scope": "server",
- "docId": "kibAlertingPluginApi",
- "section": "def-server.PublicAlert",
- "text": "PublicAlert"
- },
- "; hasReachedAlertLimit: () => boolean; done: () => ",
- "AlertFactoryDoneUtils",
- "; }"
+ "Pick<",
+ "AlertFactory",
+ ", \"done\" | \"create\"> & { alertLimit: Pick<{ getValue: () => number; setLimitReached: (reached: boolean) => void; checkLimitUsage: () => void; }, \"getValue\" | \"setLimitReached\">; }"
],
"path": "x-pack/plugins/alerting/server/types.ts",
"deprecated": false
diff --git a/api_docs/alerting.mdx b/api_docs/alerting.mdx
index b6e7a122b99d8..8a9bf5a7bf6d3 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: 2022-09-06
+date: 2022-09-07
tags: ['contributor', 'dev', 'apidocs', 'kibana', 'alerting']
---
import alertingObj from './alerting.devdocs.json';
diff --git a/api_docs/apm.devdocs.json b/api_docs/apm.devdocs.json
index ed625467a5aa2..8978452761490 100644
--- a/api_docs/apm.devdocs.json
+++ b/api_docs/apm.devdocs.json
@@ -766,7 +766,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}\" | \"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/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/{serviceName}/serviceNodes\" | \"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}/profiling/timeline\" | \"GET /internal/apm/services/{serviceName}/profiling/statistics\" | \"GET /internal/apm/services/{serviceName}/anomaly_charts\" | \"GET /internal/apm/sorted_and_filtered_services\" | \"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/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\" | \"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/alerts/chart_preview/transaction_error_rate\" | \"GET /internal/apm/alerts/chart_preview/transaction_duration\" | \"GET /internal/apm/alerts/chart_preview/transaction_error_count\" | \"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}\" | \"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\" | \"POST /internal/apm/correlations/field_stats/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/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\""
+ "\"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}\" | \"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/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/{serviceName}/serviceNodes\" | \"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}/profiling/timeline\" | \"GET /internal/apm/services/{serviceName}/profiling/statistics\" | \"GET /internal/apm/services/{serviceName}/anomaly_charts\" | \"GET /internal/apm/sorted_and_filtered_services\" | \"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/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\" | \"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/alerts/chart_preview/transaction_error_rate\" | \"GET /internal/apm/alerts/chart_preview/transaction_duration\" | \"GET /internal/apm/alerts/chart_preview/transaction_error_count\" | \"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}\" | \"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\" | \"POST /internal/apm/correlations/field_stats/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/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\""
],
"path": "x-pack/plugins/apm/server/routes/apm_routes/get_global_apm_server_route_repository.ts",
"deprecated": false,
@@ -1034,6 +1034,180 @@
"SpanLinkDetails",
"[]; }, ",
"APMRouteCreateOptions",
+ ">; \"GET /internal/apm/services/{serviceName}/storage_details\": ",
+ "ServerRoute",
+ "<\"GET /internal/apm/services/{serviceName}/storage_details\", ",
+ "TypeC",
+ "<{ path: ",
+ "TypeC",
+ "<{ serviceName: ",
+ "StringC",
+ "; }>; query: ",
+ "IntersectionC",
+ "<[",
+ "TypeC",
+ "<{ indexLifecyclePhase: ",
+ "UnionC",
+ "<[",
+ "LiteralC",
+ "<",
+ "IndexLifecyclePhaseSelectOption",
+ ".All>, ",
+ "LiteralC",
+ "<",
+ "IndexLifecyclePhaseSelectOption",
+ ".Hot>, ",
+ "LiteralC",
+ "<",
+ "IndexLifecyclePhaseSelectOption",
+ ".Warm>, ",
+ "LiteralC",
+ "<",
+ "IndexLifecyclePhaseSelectOption",
+ ".Cold>, ",
+ "LiteralC",
+ "<",
+ "IndexLifecyclePhaseSelectOption",
+ ".Frozen>]>; }>, ",
+ "TypeC",
+ "<{ probability: ",
+ "Type",
+ "; }>, ",
+ "TypeC",
+ "<{ environment: ",
+ "UnionC",
+ "<[",
+ "LiteralC",
+ "<\"ENVIRONMENT_NOT_DEFINED\">, ",
+ "LiteralC",
+ "<\"ENVIRONMENT_ALL\">, ",
+ "BrandC",
+ "<",
+ "StringC",
+ ", ",
+ "NonEmptyStringBrand",
+ ">]>; }>, ",
+ "TypeC",
+ "<{ kuery: ",
+ "StringC",
+ "; }>, ",
+ "TypeC",
+ "<{ start: ",
+ "Type",
+ "; end: ",
+ "Type",
+ "; }>]>; }>, ",
+ {
+ "pluginId": "apm",
+ "scope": "server",
+ "docId": "kibApmPluginApi",
+ "section": "def-server.APMRouteHandlerResources",
+ "text": "APMRouteHandlerResources"
+ },
+ ", { processorEventStats: { processorEvent: ",
+ {
+ "pluginId": "observability",
+ "scope": "common",
+ "docId": "kibObservabilityPluginApi",
+ "section": "def-common.ProcessorEvent",
+ "text": "ProcessorEvent"
+ },
+ ".transaction | ",
+ {
+ "pluginId": "observability",
+ "scope": "common",
+ "docId": "kibObservabilityPluginApi",
+ "section": "def-common.ProcessorEvent",
+ "text": "ProcessorEvent"
+ },
+ ".error | ",
+ {
+ "pluginId": "observability",
+ "scope": "common",
+ "docId": "kibObservabilityPluginApi",
+ "section": "def-common.ProcessorEvent",
+ "text": "ProcessorEvent"
+ },
+ ".metric | ",
+ {
+ "pluginId": "observability",
+ "scope": "common",
+ "docId": "kibObservabilityPluginApi",
+ "section": "def-common.ProcessorEvent",
+ "text": "ProcessorEvent"
+ },
+ ".span; docs: number; size: number; }[]; }, ",
+ "APMRouteCreateOptions",
+ ">; \"GET /internal/apm/storage_explorer\": ",
+ "ServerRoute",
+ "<\"GET /internal/apm/storage_explorer\", ",
+ "TypeC",
+ "<{ query: ",
+ "IntersectionC",
+ "<[",
+ "TypeC",
+ "<{ indexLifecyclePhase: ",
+ "UnionC",
+ "<[",
+ "LiteralC",
+ "<",
+ "IndexLifecyclePhaseSelectOption",
+ ".All>, ",
+ "LiteralC",
+ "<",
+ "IndexLifecyclePhaseSelectOption",
+ ".Hot>, ",
+ "LiteralC",
+ "<",
+ "IndexLifecyclePhaseSelectOption",
+ ".Warm>, ",
+ "LiteralC",
+ "<",
+ "IndexLifecyclePhaseSelectOption",
+ ".Cold>, ",
+ "LiteralC",
+ "<",
+ "IndexLifecyclePhaseSelectOption",
+ ".Frozen>]>; }>, ",
+ "TypeC",
+ "<{ probability: ",
+ "Type",
+ "; }>, ",
+ "TypeC",
+ "<{ environment: ",
+ "UnionC",
+ "<[",
+ "LiteralC",
+ "<\"ENVIRONMENT_NOT_DEFINED\">, ",
+ "LiteralC",
+ "<\"ENVIRONMENT_ALL\">, ",
+ "BrandC",
+ "<",
+ "StringC",
+ ", ",
+ "NonEmptyStringBrand",
+ ">]>; }>, ",
+ "TypeC",
+ "<{ kuery: ",
+ "StringC",
+ "; }>, ",
+ "TypeC",
+ "<{ start: ",
+ "Type",
+ "; end: ",
+ "Type",
+ "; }>]>; }>, ",
+ {
+ "pluginId": "apm",
+ "scope": "server",
+ "docId": "kibApmPluginApi",
+ "section": "def-server.APMRouteHandlerResources",
+ "text": "APMRouteHandlerResources"
+ },
+ ", { serviceStatistics: { serviceName: string; environments: string[]; size?: number | undefined; agentName: ",
+ "AgentName",
+ "; sampling: number; }[]; }, ",
+ "APMRouteCreateOptions",
">; \"POST /api/apm/agent_keys\": ",
"ServerRoute",
"<\"POST /api/apm/agent_keys\", ",
diff --git a/api_docs/apm.mdx b/api_docs/apm.mdx
index 4e114e6ce7d9d..2e85e0fe7e82f 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: 2022-09-06
+date: 2022-09-07
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 |
|-------------------|-----------|------------------------|-----------------|
-| 39 | 0 | 39 | 53 |
+| 39 | 0 | 39 | 54 |
## Client
diff --git a/api_docs/banners.mdx b/api_docs/banners.mdx
index b35e46e031865..c190b176152f5 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: 2022-09-06
+date: 2022-09-07
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 0f57ba70b9999..b0c8194872e26 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: 2022-09-06
+date: 2022-09-07
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 1089cd897c6b7..276cbb7914051 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: 2022-09-06
+date: 2022-09-07
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 bae623080dd49..de34d7c6f182f 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: 2022-09-06
+date: 2022-09-07
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 119f98090c69c..b5f95655fc358 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: 2022-09-06
+date: 2022-09-07
tags: ['contributor', 'dev', 'apidocs', 'kibana', 'charts']
---
import chartsObj from './charts.devdocs.json';
diff --git a/api_docs/cloud.mdx b/api_docs/cloud.mdx
index 5b3e4e0cbf942..aebf49b716dd5 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: 2022-09-06
+date: 2022-09-07
tags: ['contributor', 'dev', 'apidocs', 'kibana', 'cloud']
---
import cloudObj from './cloud.devdocs.json';
diff --git a/api_docs/cloud_security_posture.mdx b/api_docs/cloud_security_posture.mdx
index 3e8905668c8d4..0276b3739e55a 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: 2022-09-06
+date: 2022-09-07
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 9c4fd3cc41fa2..7a23bea6db7cd 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: 2022-09-06
+date: 2022-09-07
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 20457823815f1..c21c9db5e5463 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: 2022-09-06
+date: 2022-09-07
tags: ['contributor', 'dev', 'apidocs', 'kibana', 'controls']
---
import controlsObj from './controls.devdocs.json';
diff --git a/api_docs/core.mdx b/api_docs/core.mdx
index b6ad920381910..edf01ee9974ec 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: 2022-09-06
+date: 2022-09-07
tags: ['contributor', 'dev', 'apidocs', 'kibana', 'core']
---
import coreObj from './core.devdocs.json';
diff --git a/api_docs/custom_integrations.mdx b/api_docs/custom_integrations.mdx
index fdf8aa7725835..625584f45193f 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: 2022-09-06
+date: 2022-09-07
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 65c57db79c2af..2cd9fcacf7d98 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: 2022-09-06
+date: 2022-09-07
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 aa2aa87ee52a7..b077c478de0cc 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: 2022-09-06
+date: 2022-09-07
tags: ['contributor', 'dev', 'apidocs', 'kibana', 'dashboardEnhanced']
---
import dashboardEnhancedObj from './dashboard_enhanced.devdocs.json';
diff --git a/api_docs/data.mdx b/api_docs/data.mdx
index 99552239dbef9..f54e2978ca8a6 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: 2022-09-06
+date: 2022-09-07
tags: ['contributor', 'dev', 'apidocs', 'kibana', 'data']
---
import dataObj from './data.devdocs.json';
diff --git a/api_docs/data_query.mdx b/api_docs/data_query.mdx
index d6720e43f79a0..18b53b499a333 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: 2022-09-06
+date: 2022-09-07
tags: ['contributor', 'dev', 'apidocs', 'kibana', 'data.query']
---
import dataQueryObj from './data_query.devdocs.json';
diff --git a/api_docs/data_search.mdx b/api_docs/data_search.mdx
index f14af11637017..74e13d9570f5b 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: 2022-09-06
+date: 2022-09-07
tags: ['contributor', 'dev', 'apidocs', 'kibana', 'data.search']
---
import dataSearchObj from './data_search.devdocs.json';
diff --git a/api_docs/data_view_editor.mdx b/api_docs/data_view_editor.mdx
index fc634e4d510b6..7ca46f2f9b2f6 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: 2022-09-06
+date: 2022-09-07
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 c6c3f2195b0d4..0cdf89833b5ed 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: 2022-09-06
+date: 2022-09-07
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 d1bd53a5b473d..1d2347c970684 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: 2022-09-06
+date: 2022-09-07
tags: ['contributor', 'dev', 'apidocs', 'kibana', 'dataViewManagement']
---
import dataViewManagementObj from './data_view_management.devdocs.json';
diff --git a/api_docs/data_views.mdx b/api_docs/data_views.mdx
index 36572e12aa0fb..3d988fdd09ce8 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: 2022-09-06
+date: 2022-09-07
tags: ['contributor', 'dev', 'apidocs', 'kibana', 'dataViews']
---
import dataViewsObj from './data_views.devdocs.json';
diff --git a/api_docs/data_visualizer.mdx b/api_docs/data_visualizer.mdx
index e4d5440bfdc62..4e9386cdeb115 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: 2022-09-06
+date: 2022-09-07
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 2787cf4d1e205..fae055410e80d 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: 2022-09-06
+date: 2022-09-07
tags: ['contributor', 'dev', 'apidocs', 'kibana']
---
diff --git a/api_docs/deprecations_by_plugin.mdx b/api_docs/deprecations_by_plugin.mdx
index 97608bb1d2beb..6ee2ce05ca346 100644
--- a/api_docs/deprecations_by_plugin.mdx
+++ b/api_docs/deprecations_by_plugin.mdx
@@ -7,7 +7,7 @@ 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: 2022-09-06
+date: 2022-09-07
tags: ['contributor', 'dev', 'apidocs', 'kibana']
---
diff --git a/api_docs/deprecations_by_team.mdx b/api_docs/deprecations_by_team.mdx
index 52bc8fb97533a..a1ed349b543ae 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: 2022-09-06
+date: 2022-09-07
tags: ['contributor', 'dev', 'apidocs', 'kibana']
---
diff --git a/api_docs/dev_tools.mdx b/api_docs/dev_tools.mdx
index 0873f90539744..b64cb0dc30471 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: 2022-09-06
+date: 2022-09-07
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 f3620385ddcae..e2b70f2f8e129 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: 2022-09-06
+date: 2022-09-07
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 11b53e7d81f85..dc4decbf959c0 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: 2022-09-06
+date: 2022-09-07
tags: ['contributor', 'dev', 'apidocs', 'kibana', 'discoverEnhanced']
---
import discoverEnhancedObj from './discover_enhanced.devdocs.json';
diff --git a/api_docs/embeddable.mdx b/api_docs/embeddable.mdx
index 9e302d3ec385f..1374109c4a066 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: 2022-09-06
+date: 2022-09-07
tags: ['contributor', 'dev', 'apidocs', 'kibana', 'embeddable']
---
import embeddableObj from './embeddable.devdocs.json';
diff --git a/api_docs/embeddable_enhanced.mdx b/api_docs/embeddable_enhanced.mdx
index f83fd634dea26..2af55b586ee99 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: 2022-09-06
+date: 2022-09-07
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 ff50fc4962b25..07f95dd49ff0c 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: 2022-09-06
+date: 2022-09-07
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 2f4a97083f119..afde3b98dcafe 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: 2022-09-06
+date: 2022-09-07
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 aea9650756ddc..cb4c439d84790 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: 2022-09-06
+date: 2022-09-07
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 2b74a26ae25c4..b3c097214b2d3 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: 2022-09-06
+date: 2022-09-07
tags: ['contributor', 'dev', 'apidocs', 'kibana', 'eventAnnotation']
---
import eventAnnotationObj from './event_annotation.devdocs.json';
diff --git a/api_docs/event_log.mdx b/api_docs/event_log.mdx
index 6b34c4088e9ae..3a80cc15aa5cf 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: 2022-09-06
+date: 2022-09-07
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 ff4979afd3ce7..6e02317db49a7 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: 2022-09-06
+date: 2022-09-07
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 750366930004f..594f3bb4d24d1 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: 2022-09-06
+date: 2022-09-07
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 a58b72f20bf77..3e69a97bd0c00 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: 2022-09-06
+date: 2022-09-07
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 54fcdd0bde2a4..73cc90d657426 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: 2022-09-06
+date: 2022-09-07
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 7964d4d21c4c3..e4093ceac07ae 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: 2022-09-06
+date: 2022-09-07
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 cece7f9474b8b..be5929fd38d56 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: 2022-09-06
+date: 2022-09-07
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 fbfa28ccf68c7..4a0503e48459f 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: 2022-09-06
+date: 2022-09-07
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 d063673a50c14..953697f936c6b 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: 2022-09-06
+date: 2022-09-07
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 2b6681ae06216..e540c032935db 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: 2022-09-06
+date: 2022-09-07
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 c93ab7f345bc4..e7342d04da9da 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: 2022-09-06
+date: 2022-09-07
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 ac98185499d10..fbd0b000fa930 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: 2022-09-06
+date: 2022-09-07
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 daaad8d675c9c..a0056c7338d74 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: 2022-09-06
+date: 2022-09-07
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 5ebc4a9811f32..a395c0c178b5c 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: 2022-09-06
+date: 2022-09-07
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 e10f5c5cbe402..fdc07fa4327a9 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: 2022-09-06
+date: 2022-09-07
tags: ['contributor', 'dev', 'apidocs', 'kibana', 'expressions']
---
import expressionsObj from './expressions.devdocs.json';
diff --git a/api_docs/features.mdx b/api_docs/features.mdx
index 1776e4a6585bf..20d3e481faa4c 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: 2022-09-06
+date: 2022-09-07
tags: ['contributor', 'dev', 'apidocs', 'kibana', 'features']
---
import featuresObj from './features.devdocs.json';
diff --git a/api_docs/field_formats.mdx b/api_docs/field_formats.mdx
index d5aed3858f71a..34912547e5471 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: 2022-09-06
+date: 2022-09-07
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 c283935c62f52..9f538899acbab 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: 2022-09-06
+date: 2022-09-07
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 46d4068ca249f..ecbf04950569d 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: 2022-09-06
+date: 2022-09-07
tags: ['contributor', 'dev', 'apidocs', 'kibana', 'files']
---
import filesObj from './files.devdocs.json';
diff --git a/api_docs/fleet.mdx b/api_docs/fleet.mdx
index cfd98cbe95dc6..ee8c31d150902 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: 2022-09-06
+date: 2022-09-07
tags: ['contributor', 'dev', 'apidocs', 'kibana', 'fleet']
---
import fleetObj from './fleet.devdocs.json';
diff --git a/api_docs/global_search.mdx b/api_docs/global_search.mdx
index ab12dca075c19..64fc79df18c3a 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: 2022-09-06
+date: 2022-09-07
tags: ['contributor', 'dev', 'apidocs', 'kibana', 'globalSearch']
---
import globalSearchObj from './global_search.devdocs.json';
diff --git a/api_docs/home.mdx b/api_docs/home.mdx
index 55e90c0516af2..d60024bdaed5b 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: 2022-09-06
+date: 2022-09-07
tags: ['contributor', 'dev', 'apidocs', 'kibana', 'home']
---
import homeObj from './home.devdocs.json';
diff --git a/api_docs/index_lifecycle_management.mdx b/api_docs/index_lifecycle_management.mdx
index de87d26f24bf2..e506c2a95a464 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: 2022-09-06
+date: 2022-09-07
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 3c324136f039e..d1ee511f1b26d 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: 2022-09-06
+date: 2022-09-07
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 939d4b806fb0b..73daf81d33975 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: 2022-09-06
+date: 2022-09-07
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 3acad0bdb0c5b..f6aab686bb8df 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: 2022-09-06
+date: 2022-09-07
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 2ada44f7c245e..5b566585577e8 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: 2022-09-06
+date: 2022-09-07
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 dce075233c681..c01b9a72036c9 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: 2022-09-06
+date: 2022-09-07
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 8fe2e18f681e4..632f2a5f148c2 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: 2022-09-06
+date: 2022-09-07
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 35adae134ef06..f3c241c01bfe0 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: 2022-09-06
+date: 2022-09-07
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 6be99347740b7..2080343d9bd79 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: 2022-09-06
+date: 2022-09-07
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 26b13591e0df1..e6b1e884f8289 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: 2022-09-06
+date: 2022-09-07
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 eb9dd53dad393..a09dd84d4427a 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: 2022-09-06
+date: 2022-09-07
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 cf097f3adea04..51a1b4b37dfa7 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: 2022-09-06
+date: 2022-09-07
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 f5a13ef20025c..2e323e811b1e6 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: 2022-09-06
+date: 2022-09-07
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 0b4ace5c97070..bfe5e552baf73 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: 2022-09-06
+date: 2022-09-07
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 2a43b4ad73fd1..9c204be3d61a9 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: 2022-09-06
+date: 2022-09-07
tags: ['contributor', 'dev', 'apidocs', 'kibana', '@kbn/analytics-shippers-fullstory']
---
import kbnAnalyticsShippersFullstoryObj from './kbn_analytics_shippers_fullstory.devdocs.json';
diff --git a/api_docs/kbn_apm_config_loader.mdx b/api_docs/kbn_apm_config_loader.mdx
index 41d191bffce76..3456e4a1954b6 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: 2022-09-06
+date: 2022-09-07
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.devdocs.json b/api_docs/kbn_apm_synthtrace.devdocs.json
index 142d988330fbd..02fecd0c5eb47 100644
--- a/api_docs/kbn_apm_synthtrace.devdocs.json
+++ b/api_docs/kbn_apm_synthtrace.devdocs.json
@@ -192,13 +192,28 @@
"label": "refresh",
"description": [],
"signature": [
- "() => Promise<",
+ "(dataStreams?: string[] | undefined) => Promise<",
"ShardsOperationResponseBase",
">"
],
"path": "packages/kbn-apm-synthtrace/src/lib/apm/client/apm_synthtrace_es_client.ts",
"deprecated": false,
- "children": [],
+ "children": [
+ {
+ "parentPluginId": "@kbn/apm-synthtrace",
+ "id": "def-server.ApmSynthtraceEsClient.refresh.$1",
+ "type": "Array",
+ "tags": [],
+ "label": "dataStreams",
+ "description": [],
+ "signature": [
+ "string[] | undefined"
+ ],
+ "path": "packages/kbn-apm-synthtrace/src/lib/apm/client/apm_synthtrace_es_client.ts",
+ "deprecated": false,
+ "isRequired": false
+ }
+ ],
"returnComment": []
},
{
@@ -455,10 +470,10 @@
},
{
"parentPluginId": "@kbn/apm-synthtrace",
- "id": "def-server.EntityArrayIterable.ratePerMinute",
+ "id": "def-server.EntityArrayIterable.estimatedRatePerMinute",
"type": "Function",
"tags": [],
- "label": "ratePerMinute",
+ "label": "estimatedRatePerMinute",
"description": [],
"signature": [
"() => number"
@@ -805,10 +820,10 @@
},
{
"parentPluginId": "@kbn/apm-synthtrace",
- "id": "def-server.EntityIterable.ratePerMinute",
+ "id": "def-server.EntityIterable.estimatedRatePerMinute",
"type": "Function",
"tags": [],
- "label": "ratePerMinute",
+ "label": "estimatedRatePerMinute",
"description": [],
"signature": [
"() => number"
diff --git a/api_docs/kbn_apm_synthtrace.mdx b/api_docs/kbn_apm_synthtrace.mdx
index 4f40b0e9ba98b..9aa1c9da7a26c 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: 2022-09-06
+date: 2022-09-07
tags: ['contributor', 'dev', 'apidocs', 'kibana', '@kbn/apm-synthtrace']
---
import kbnApmSynthtraceObj from './kbn_apm_synthtrace.devdocs.json';
@@ -21,7 +21,7 @@ Contact [Owner missing] for questions regarding this plugin.
| Public API count | Any count | Items lacking comments | Missing exports |
|-------------------|-----------|------------------------|-----------------|
-| 75 | 0 | 75 | 12 |
+| 76 | 0 | 76 | 12 |
## Server
diff --git a/api_docs/kbn_apm_utils.mdx b/api_docs/kbn_apm_utils.mdx
index 227a95bbdc22e..80300e4b34789 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: 2022-09-06
+date: 2022-09-07
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 b2ffd9c43784b..de6bb8999931b 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: 2022-09-06
+date: 2022-09-07
tags: ['contributor', 'dev', 'apidocs', 'kibana', '@kbn/axe-config']
---
import kbnAxeConfigObj from './kbn_axe_config.devdocs.json';
diff --git a/api_docs/kbn_chart_icons.mdx b/api_docs/kbn_chart_icons.mdx
index 858efed44444c..263e793b011a0 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: 2022-09-06
+date: 2022-09-07
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 402bf52a1f22f..d65af3ce467da 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: 2022-09-06
+date: 2022-09-07
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 5968959cd3961..7e24e3e42435a 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: 2022-09-06
+date: 2022-09-07
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 97e4463e24e0c..64816e9963b89 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: 2022-09-06
+date: 2022-09-07
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 5f71bc4cde520..6ea459146251a 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: 2022-09-06
+date: 2022-09-07
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 6a345a79bc6c4..5c72a688d0b17 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: 2022-09-06
+date: 2022-09-07
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 293f300c3b260..abea714b90bf9 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: 2022-09-06
+date: 2022-09-07
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 f763976f6427b..49893743e1d9d 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: 2022-09-06
+date: 2022-09-07
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 1047ba87b6643..a651937e567c1 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: 2022-09-06
+date: 2022-09-07
tags: ['contributor', 'dev', 'apidocs', 'kibana', '@kbn/config-schema']
---
import kbnConfigSchemaObj from './kbn_config_schema.devdocs.json';
diff --git a/api_docs/kbn_core_analytics_browser.mdx b/api_docs/kbn_core_analytics_browser.mdx
index 77444ae7f6a05..cced6551c1ff8 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: 2022-09-06
+date: 2022-09-07
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 5ac4b3104f341..e67c33689204f 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: 2022-09-06
+date: 2022-09-07
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 01e1c13a9fd76..a8122ae1841df 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: 2022-09-06
+date: 2022-09-07
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 514ed035def29..a4c7c89224b47 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: 2022-09-06
+date: 2022-09-07
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 4d02dee208b91..71b38bfeeb32a 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: 2022-09-06
+date: 2022-09-07
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 b68bbadb1b949..ff3b13f7e0bab 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: 2022-09-06
+date: 2022-09-07
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.mdx b/api_docs/kbn_core_application_browser.mdx
index 9e0a126f80542..f2a9a027e387c 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: 2022-09-06
+date: 2022-09-07
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 ebb267f8b9dc8..3a170052d9bd0 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: 2022-09-06
+date: 2022-09-07
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 aa6cf87a21193..49e6be4e8bcf5 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: 2022-09-06
+date: 2022-09-07
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 b7a0df2ff0356..506c874ec4cd2 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: 2022-09-06
+date: 2022-09-07
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_base_browser_mocks.mdx b/api_docs/kbn_core_base_browser_mocks.mdx
index 2cf240d31d76f..8491ba8253b9e 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: 2022-09-06
+date: 2022-09-07
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 82457300e0524..5a7de06ce3e5b 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: 2022-09-06
+date: 2022-09-07
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 5c75439893d98..e52771051b34c 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: 2022-09-06
+date: 2022-09-07
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 72020ac2bcd34..975a976dc152b 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: 2022-09-06
+date: 2022-09-07
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 afe35769d50b1..a12796b3af15c 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: 2022-09-06
+date: 2022-09-07
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 762be5fb47ecc..1608bdfdf6db8 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: 2022-09-06
+date: 2022-09-07
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 1c58618bae110..b8e203778c69d 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: 2022-09-06
+date: 2022-09-07
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 eea481cff9efc..ac75a699b4b89 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: 2022-09-06
+date: 2022-09-07
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.mdx b/api_docs/kbn_core_chrome_browser.mdx
index 3fa5ef98dce64..4fee44df05051 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: 2022-09-06
+date: 2022-09-07
tags: ['contributor', 'dev', 'apidocs', 'kibana', '@kbn/core-chrome-browser']
---
import kbnCoreChromeBrowserObj from './kbn_core_chrome_browser.devdocs.json';
diff --git a/api_docs/kbn_core_chrome_browser_mocks.mdx b/api_docs/kbn_core_chrome_browser_mocks.mdx
index 923481e4ccd64..3f1d420fb18ec 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: 2022-09-06
+date: 2022-09-07
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 2c2bf980a2122..d911455b3497b 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: 2022-09-06
+date: 2022-09-07
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_deprecations_browser.mdx b/api_docs/kbn_core_deprecations_browser.mdx
index 63c057fa342a6..060e08b9305d1 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: 2022-09-06
+date: 2022-09-07
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 b1d80d415129e..afea5944f3b5f 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: 2022-09-06
+date: 2022-09-07
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 2d18319a276b3..9366812463eb7 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: 2022-09-06
+date: 2022-09-07
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 b4deab8346f2f..6419e8fc767cf 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: 2022-09-06
+date: 2022-09-07
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 06dec051aa6f7..3b4b05add69c6 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: 2022-09-06
+date: 2022-09-07
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 56a00817b13a9..02f5d9aaaad9a 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: 2022-09-06
+date: 2022-09-07
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 60aecf7424070..6756e8014d30b 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: 2022-09-06
+date: 2022-09-07
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 ee9d22702424b..6ba9bf598cc7e 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: 2022-09-06
+date: 2022-09-07
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 a07efab80f14b..11e7d4685bcb1 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: 2022-09-06
+date: 2022-09-07
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 a8989f6957230..d06cec3abe119 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: 2022-09-06
+date: 2022-09-07
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 2b0274399ae1f..00abb6d88e2e1 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: 2022-09-06
+date: 2022-09-07
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 9fa17a347e6e0..ad85c66cb2b3b 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: 2022-09-06
+date: 2022-09-07
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 23dc5d40c40ce..9042a25c2da51 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: 2022-09-06
+date: 2022-09-07
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 e51873a4ffe4c..34dfef3b2d414 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: 2022-09-06
+date: 2022-09-07
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 a2947b7d28466..e3dd1661d7e13 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: 2022-09-06
+date: 2022-09-07
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 48c485334349e..29efd2e709aea 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: 2022-09-06
+date: 2022-09-07
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 89ebe82053604..3595e65887876 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: 2022-09-06
+date: 2022-09-07
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 dad8a14043fae..d0a30864e23aa 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: 2022-09-06
+date: 2022-09-07
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 8724bf34779ad..e45a81606c8c7 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: 2022-09-06
+date: 2022-09-07
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 5008328a2b6ef..e4b3b1e95cd2a 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: 2022-09-06
+date: 2022-09-07
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 e5a186c7fafc1..3ab2769e33a69 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: 2022-09-06
+date: 2022-09-07
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 602b4baf794fa..4db2dafa511d5 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: 2022-09-06
+date: 2022-09-07
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 cef1df0e4ed92..fb3e552f693e1 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: 2022-09-06
+date: 2022-09-07
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 38f8fc08be9f5..5f87409e412fa 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: 2022-09-06
+date: 2022-09-07
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 36f42437d1100..9afcc9d17b590 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: 2022-09-06
+date: 2022-09-07
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 2351e1c161fe1..0700a5bd07585 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: 2022-09-06
+date: 2022-09-07
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 058eb732b1480..e1e3ac247fa36 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: 2022-09-06
+date: 2022-09-07
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 a0976872ed52b..72996ffb91fc1 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: 2022-09-06
+date: 2022-09-07
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 2850d141de4e2..8cc109d0568c4 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: 2022-09-06
+date: 2022-09-07
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 1f22e8afefdd5..ede088fc5c6ed 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: 2022-09-06
+date: 2022-09-07
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 072f8e7467992..0710d493a91de 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: 2022-09-06
+date: 2022-09-07
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 cd815fc819739..549356ea922dd 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: 2022-09-06
+date: 2022-09-07
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_router_server_internal.mdx b/api_docs/kbn_core_http_router_server_internal.mdx
index 97203df57f813..743c5faad92dd 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: 2022-09-06
+date: 2022-09-07
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 57b23bc813c76..3765c360063b5 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: 2022-09-06
+date: 2022-09-07
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 5ea85d8edec6c..cc2d7b611c770 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: 2022-09-06
+date: 2022-09-07
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 67fbb1f0bc13f..563876c4a598f 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: 2022-09-06
+date: 2022-09-07
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.mdx b/api_docs/kbn_core_http_server_mocks.mdx
index a8f08144c9c6f..bc9ac7b997e58 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: 2022-09-06
+date: 2022-09-07
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 118c6d56caa16..d94defae7a668 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: 2022-09-06
+date: 2022-09-07
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 2eebb6ad333a7..3e96a8b24521f 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: 2022-09-06
+date: 2022-09-07
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 6767d040b15bd..c203ca6978159 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: 2022-09-06
+date: 2022-09-07
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 e2a3f1ccdba2a..d5ddcabbc6999 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: 2022-09-06
+date: 2022-09-07
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 0f63e78634e39..23ac231f7db12 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: 2022-09-06
+date: 2022-09-07
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.mdx b/api_docs/kbn_core_injected_metadata_browser.mdx
index 8cbbf6ec24436..cec8c3d113cd1 100644
--- a/api_docs/kbn_core_injected_metadata_browser.mdx
+++ b/api_docs/kbn_core_injected_metadata_browser.mdx
@@ -8,7 +8,7 @@ slug: /kibana-dev-docs/api/kbn-core-injected-metadata-browser
title: "@kbn/core-injected-metadata-browser"
image: https://source.unsplash.com/400x175/?github
description: API docs for the @kbn/core-injected-metadata-browser plugin
-date: 2022-09-06
+date: 2022-09-07
tags: ['contributor', 'dev', 'apidocs', 'kibana', '@kbn/core-injected-metadata-browser']
---
import kbnCoreInjectedMetadataBrowserObj from './kbn_core_injected_metadata_browser.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 43feff34842f8..1b9cd30610cca 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: 2022-09-06
+date: 2022-09-07
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 c714e9b9aff2e..5b9fc23e7d3a8 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: 2022-09-06
+date: 2022-09-07
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 e16dedb121036..4a81fe638eeab 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: 2022-09-06
+date: 2022-09-07
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_logging_server.mdx b/api_docs/kbn_core_logging_server.mdx
index e5f404928d37a..05112105e62f3 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: 2022-09-06
+date: 2022-09-07
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 f183ecbb1dcdd..11957d79313cd 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: 2022-09-06
+date: 2022-09-07
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 c3cb65884623f..c18e67ef31e11 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: 2022-09-06
+date: 2022-09-07
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 00bc0e02d96ed..d6fe2392825a7 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: 2022-09-06
+date: 2022-09-07
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 1fe22f5e361a1..9744bead247c6 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: 2022-09-06
+date: 2022-09-07
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.mdx b/api_docs/kbn_core_metrics_server.mdx
index e98d848279e20..12ac7ef4a9186 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: 2022-09-06
+date: 2022-09-07
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 c3a18f9c6a33e..97d5b806d4c9c 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: 2022-09-06
+date: 2022-09-07
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 677c0a7dded87..ad77881dbde21 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: 2022-09-06
+date: 2022-09-07
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 0d3b2d3504b7a..796cbbf70a804 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: 2022-09-06
+date: 2022-09-07
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 1ff5ddeb716ed..beae867b6bf46 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: 2022-09-06
+date: 2022-09-07
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 aae4a1dc3b3d2..affb582e10268 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: 2022-09-06
+date: 2022-09-07
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 337b689956aa4..4dace8ae3cb17 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: 2022-09-06
+date: 2022-09-07
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 e6803d2caa7b1..c1c3edd3c57e4 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: 2022-09-06
+date: 2022-09-07
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 232561f049ce9..3db1fb6f2dd25 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: 2022-09-06
+date: 2022-09-07
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 97ee4827d1b68..885fd16e2b57d 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: 2022-09-06
+date: 2022-09-07
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 0bea9b5c52b6b..2889cd8452e04 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: 2022-09-06
+date: 2022-09-07
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 1a9a5dbede6a8..2c1b459fca665 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: 2022-09-06
+date: 2022-09-07
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 99284e993eab5..933e7d688b1c8 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: 2022-09-06
+date: 2022-09-07
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_preboot_server.mdx b/api_docs/kbn_core_preboot_server.mdx
index d5a2cd88b46d3..547fe04c217b3 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: 2022-09-06
+date: 2022-09-07
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 e1f23bc02e5d9..1ccfed0911f4b 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: 2022-09-06
+date: 2022-09-07
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.devdocs.json b/api_docs/kbn_core_rendering_browser_mocks.devdocs.json
new file mode 100644
index 0000000000000..f405033465ab1
--- /dev/null
+++ b/api_docs/kbn_core_rendering_browser_mocks.devdocs.json
@@ -0,0 +1,56 @@
+{
+ "id": "@kbn/core-rendering-browser-mocks",
+ "client": {
+ "classes": [],
+ "functions": [],
+ "interfaces": [],
+ "enums": [],
+ "misc": [],
+ "objects": []
+ },
+ "server": {
+ "classes": [],
+ "functions": [],
+ "interfaces": [],
+ "enums": [],
+ "misc": [],
+ "objects": []
+ },
+ "common": {
+ "classes": [],
+ "functions": [],
+ "interfaces": [],
+ "enums": [],
+ "misc": [],
+ "objects": [
+ {
+ "parentPluginId": "@kbn/core-rendering-browser-mocks",
+ "id": "def-common.renderingServiceMock",
+ "type": "Object",
+ "tags": [],
+ "label": "renderingServiceMock",
+ "description": [],
+ "path": "packages/core/rendering/core-rendering-browser-mocks/src/rendering_service.mock.ts",
+ "deprecated": false,
+ "children": [
+ {
+ "parentPluginId": "@kbn/core-rendering-browser-mocks",
+ "id": "def-common.renderingServiceMock.create",
+ "type": "Function",
+ "tags": [],
+ "label": "create",
+ "description": [],
+ "signature": [
+ "() => jest.Mocked"
+ ],
+ "path": "packages/core/rendering/core-rendering-browser-mocks/src/rendering_service.mock.ts",
+ "deprecated": false,
+ "returnComment": [],
+ "children": []
+ }
+ ],
+ "initialIsOpen": false
+ }
+ ]
+ }
+}
\ No newline at end of file
diff --git a/api_docs/kbn_core_rendering_browser_mocks.mdx b/api_docs/kbn_core_rendering_browser_mocks.mdx
new file mode 100644
index 0000000000000..77e0b0a1680d8
--- /dev/null
+++ b/api_docs/kbn_core_rendering_browser_mocks.mdx
@@ -0,0 +1,30 @@
+---
+####
+#### 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: kibKbnCoreRenderingBrowserMocksPluginApi
+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: 2022-09-07
+tags: ['contributor', 'dev', 'apidocs', 'kibana', '@kbn/core-rendering-browser-mocks']
+---
+import kbnCoreRenderingBrowserMocksObj from './kbn_core_rendering_browser_mocks.devdocs.json';
+
+
+
+Contact Kibana Core for questions regarding this plugin.
+
+**Code health stats**
+
+| Public API count | Any count | Items lacking comments | Missing exports |
+|-------------------|-----------|------------------------|-----------------|
+| 2 | 0 | 2 | 0 |
+
+## Common
+
+### Objects
+
+
diff --git a/api_docs/kbn_core_saved_objects_api_browser.mdx b/api_docs/kbn_core_saved_objects_api_browser.mdx
index 36fadbfa56b7c..53a2455a429b5 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: 2022-09-06
+date: 2022-09-07
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 9d78c2e380058..fd5b8c0a19644 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: 2022-09-06
+date: 2022-09-07
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 dfef7401613af..3cef779cc7260 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: 2022-09-06
+date: 2022-09-07
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 bebb651b194ef..f895de6bfb934 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: 2022-09-06
+date: 2022-09-07
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 376b28746f40c..11394ad658932 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: 2022-09-06
+date: 2022-09-07
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 2ecce4465af82..c9dfd0f25e3e0 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: 2022-09-06
+date: 2022-09-07
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.mdx b/api_docs/kbn_core_saved_objects_browser.mdx
index 00f720e9d5185..3356adad0bd61 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: 2022-09-06
+date: 2022-09-07
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.mdx b/api_docs/kbn_core_saved_objects_browser_internal.mdx
index b3c9ce41ddea5..d232918c826a2 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: 2022-09-06
+date: 2022-09-07
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.mdx b/api_docs/kbn_core_saved_objects_browser_mocks.mdx
index 1da0166565b44..4cc117386d965 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: 2022-09-06
+date: 2022-09-07
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.mdx b/api_docs/kbn_core_saved_objects_common.mdx
index bcc2e28dcd51a..f58f02d51a311 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: 2022-09-06
+date: 2022-09-07
tags: ['contributor', 'dev', 'apidocs', 'kibana', '@kbn/core-saved-objects-common']
---
import kbnCoreSavedObjectsCommonObj from './kbn_core_saved_objects_common.devdocs.json';
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 6b7ee7af63ae4..e27ea4e4d13ee 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: 2022-09-06
+date: 2022-09-07
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 af070bd29e18f..2eabd993dc56a 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: 2022-09-06
+date: 2022-09-07
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 fb6abb141aa95..53a8f144297bd 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: 2022-09-06
+date: 2022-09-07
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 7da28fe940c34..9e1eb09b68d6e 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: 2022-09-06
+date: 2022-09-07
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.mdx b/api_docs/kbn_core_saved_objects_server.mdx
index db9eb21dea863..001f3310eb837 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: 2022-09-06
+date: 2022-09-07
tags: ['contributor', 'dev', 'apidocs', 'kibana', '@kbn/core-saved-objects-server']
---
import kbnCoreSavedObjectsServerObj from './kbn_core_saved_objects_server.devdocs.json';
diff --git a/api_docs/kbn_core_saved_objects_server_internal.mdx b/api_docs/kbn_core_saved_objects_server_internal.mdx
index ddb5b3dfa0156..4f71783ecfb78 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: 2022-09-06
+date: 2022-09-07
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 4d967c6814712..8dbfbc37b91a1 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: 2022-09-06
+date: 2022-09-07
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 8b918ee989f7e..8445223e4eb69 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: 2022-09-06
+date: 2022-09-07
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_test_helpers_deprecations_getters.mdx b/api_docs/kbn_core_test_helpers_deprecations_getters.mdx
index cc647fd4f441b..5f832eb197d7e 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: 2022-09-06
+date: 2022-09-07
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 eb661078b5acc..9cd629f974d1c 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: 2022-09-06
+date: 2022-09-07
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_theme_browser.mdx b/api_docs/kbn_core_theme_browser.mdx
index bcfd796c5a5ca..be476afa5a8fe 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: 2022-09-06
+date: 2022-09-07
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 2f70442ddfba1..44f2d7de967ff 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: 2022-09-06
+date: 2022-09-07
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 86a7fd3fd90a5..0fa3aa1e736e6 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: 2022-09-06
+date: 2022-09-07
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 bdf97d7d0d912..51cac2cd8dd38 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: 2022-09-06
+date: 2022-09-07
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 235d9d32ca150..5cdb8cd67bb19 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: 2022-09-06
+date: 2022-09-07
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 243a50e34daef..1632aa3fa7f31 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: 2022-09-06
+date: 2022-09-07
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 764c7684d7d46..df90be94bda7a 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: 2022-09-06
+date: 2022-09-07
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_usage_data_server.mdx b/api_docs/kbn_core_usage_data_server.mdx
index b8acf29ea4e38..838dd0264b521 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: 2022-09-06
+date: 2022-09-07
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 a331ad12e0e93..cbe2ae22803d7 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: 2022-09-06
+date: 2022-09-07
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 97902b78c1e53..1b627550b4779 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: 2022-09-06
+date: 2022-09-07
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 43df99de292a3..409492d14c605 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: 2022-09-06
+date: 2022-09-07
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 2a0a4c1f03b1c..04373ff4a990a 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: 2022-09-06
+date: 2022-09-07
tags: ['contributor', 'dev', 'apidocs', 'kibana', '@kbn/crypto-browser']
---
import kbnCryptoBrowserObj from './kbn_crypto_browser.devdocs.json';
diff --git a/api_docs/kbn_datemath.mdx b/api_docs/kbn_datemath.mdx
index c32356270ffdd..df1e8f5ad7edd 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: 2022-09-06
+date: 2022-09-07
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 97011ad26711a..02597e67dae12 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: 2022-09-06
+date: 2022-09-07
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 935cda637c96f..947a11055952c 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: 2022-09-06
+date: 2022-09-07
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 b32f51201616c..e4eb5dd27b8e8 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: 2022-09-06
+date: 2022-09-07
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 c47422872ebf4..c628dc8abac4c 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: 2022-09-06
+date: 2022-09-07
tags: ['contributor', 'dev', 'apidocs', 'kibana', '@kbn/dev-utils']
---
import kbnDevUtilsObj from './kbn_dev_utils.devdocs.json';
diff --git a/api_docs/kbn_doc_links.mdx b/api_docs/kbn_doc_links.mdx
index 6dbba50fa178c..3db1eec56982f 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: 2022-09-06
+date: 2022-09-07
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 38d420864d541..8d6a3e23a00bb 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: 2022-09-06
+date: 2022-09-07
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 18b5ab724e4a0..3dc5d5692abc5 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: 2022-09-06
+date: 2022-09-07
tags: ['contributor', 'dev', 'apidocs', 'kibana', '@kbn/ebt-tools']
---
import kbnEbtToolsObj from './kbn_ebt_tools.devdocs.json';
diff --git a/api_docs/kbn_es_archiver.mdx b/api_docs/kbn_es_archiver.mdx
index a910b0ed9ab1b..8d07a0dc99a4e 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: 2022-09-06
+date: 2022-09-07
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 e5218372534ea..963f6424de304 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: 2022-09-06
+date: 2022-09-07
tags: ['contributor', 'dev', 'apidocs', 'kibana', '@kbn/es-errors']
---
import kbnEsErrorsObj from './kbn_es_errors.devdocs.json';
diff --git a/api_docs/kbn_es_query.mdx b/api_docs/kbn_es_query.mdx
index f40b2ed2c2e69..b127dfc91df35 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: 2022-09-06
+date: 2022-09-07
tags: ['contributor', 'dev', 'apidocs', 'kibana', '@kbn/es-query']
---
import kbnEsQueryObj from './kbn_es_query.devdocs.json';
diff --git a/api_docs/kbn_eslint_plugin_imports.mdx b/api_docs/kbn_eslint_plugin_imports.mdx
index a64dad8da4aca..a68bb15370d0c 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: 2022-09-06
+date: 2022-09-07
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 5cec3d061f0b3..5b97fa413ad5a 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: 2022-09-06
+date: 2022-09-07
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 bb92f973d42cd..d4d918c661bb9 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: 2022-09-06
+date: 2022-09-07
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_generate.mdx b/api_docs/kbn_generate.mdx
index 5dfff84c00067..ee1a64701a459 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: 2022-09-06
+date: 2022-09-07
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 85bcb73c7ff82..9c1fa2178ef03 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: 2022-09-06
+date: 2022-09-07
tags: ['contributor', 'dev', 'apidocs', 'kibana', '@kbn/get-repo-files']
---
import kbnGetRepoFilesObj from './kbn_get_repo_files.devdocs.json';
diff --git a/api_docs/kbn_handlebars.mdx b/api_docs/kbn_handlebars.mdx
index b72bd4ea22601..fd9eca7769507 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: 2022-09-06
+date: 2022-09-07
tags: ['contributor', 'dev', 'apidocs', 'kibana', '@kbn/handlebars']
---
import kbnHandlebarsObj from './kbn_handlebars.devdocs.json';
diff --git a/api_docs/kbn_hapi_mocks.mdx b/api_docs/kbn_hapi_mocks.mdx
index 4ec02e4804950..227c70177e1e0 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: 2022-09-06
+date: 2022-09-07
tags: ['contributor', 'dev', 'apidocs', 'kibana', '@kbn/hapi-mocks']
---
import kbnHapiMocksObj from './kbn_hapi_mocks.devdocs.json';
diff --git a/api_docs/kbn_home_sample_data_card.mdx b/api_docs/kbn_home_sample_data_card.mdx
index 44cf43df05196..601f09298a638 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: 2022-09-06
+date: 2022-09-07
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 df5c65f7b4eda..2a9c1ba10b065 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: 2022-09-06
+date: 2022-09-07
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 e4c7ca4f21d55..62c887f4a3aa1 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: 2022-09-06
+date: 2022-09-07
tags: ['contributor', 'dev', 'apidocs', 'kibana', '@kbn/i18n']
---
import kbnI18nObj from './kbn_i18n.devdocs.json';
diff --git a/api_docs/kbn_import_resolver.mdx b/api_docs/kbn_import_resolver.mdx
index 38220037bbaaa..6e015917e59ae 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: 2022-09-06
+date: 2022-09-07
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 317a6ad2677df..189abd9254817 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: 2022-09-06
+date: 2022-09-07
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 49469e3bb12b8..cdf287835bea3 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: 2022-09-06
+date: 2022-09-07
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 1efda5e4370d1..bf42dcae5f89b 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: 2022-09-06
+date: 2022-09-07
tags: ['contributor', 'dev', 'apidocs', 'kibana', '@kbn/jest-serializers']
---
import kbnJestSerializersObj from './kbn_jest_serializers.devdocs.json';
diff --git a/api_docs/kbn_kibana_manifest_parser.mdx b/api_docs/kbn_kibana_manifest_parser.mdx
index e6b10e49a9696..6e6ecb51a0452 100644
--- a/api_docs/kbn_kibana_manifest_parser.mdx
+++ b/api_docs/kbn_kibana_manifest_parser.mdx
@@ -8,7 +8,7 @@ slug: /kibana-dev-docs/api/kbn-kibana-manifest-parser
title: "@kbn/kibana-manifest-parser"
image: https://source.unsplash.com/400x175/?github
description: API docs for the @kbn/kibana-manifest-parser plugin
-date: 2022-09-06
+date: 2022-09-07
tags: ['contributor', 'dev', 'apidocs', 'kibana', '@kbn/kibana-manifest-parser']
---
import kbnKibanaManifestParserObj from './kbn_kibana_manifest_parser.devdocs.json';
diff --git a/api_docs/kbn_kibana_manifest_schema.mdx b/api_docs/kbn_kibana_manifest_schema.mdx
index 43ef3e3ba3e5e..83e80cab01f84 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: 2022-09-06
+date: 2022-09-07
tags: ['contributor', 'dev', 'apidocs', 'kibana', '@kbn/kibana-manifest-schema']
---
import kbnKibanaManifestSchemaObj from './kbn_kibana_manifest_schema.devdocs.json';
diff --git a/api_docs/kbn_logging.mdx b/api_docs/kbn_logging.mdx
index f1893197e6c1d..def8b60b0b717 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: 2022-09-06
+date: 2022-09-07
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 0457b5227adca..840df92d12bee 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: 2022-09-06
+date: 2022-09-07
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 4cccaf3476a66..16ff2f8b32459 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: 2022-09-06
+date: 2022-09-07
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 4b0b781fb1b64..214b59337f863 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: 2022-09-06
+date: 2022-09-07
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 6ce32fe93f5ea..1e8bee5a4a561 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: 2022-09-06
+date: 2022-09-07
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_is_populated_object.mdx b/api_docs/kbn_ml_is_populated_object.mdx
index cf4a767ab5c1d..27d9aaaac7cae 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: 2022-09-06
+date: 2022-09-07
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_string_hash.mdx b/api_docs/kbn_ml_string_hash.mdx
index 71601f71a4b79..d51dc9688fa94 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: 2022-09-06
+date: 2022-09-07
tags: ['contributor', 'dev', 'apidocs', 'kibana', '@kbn/ml-string-hash']
---
import kbnMlStringHashObj from './kbn_ml_string_hash.devdocs.json';
diff --git a/api_docs/kbn_monaco.mdx b/api_docs/kbn_monaco.mdx
index da9feeb48ae71..108507440c091 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: 2022-09-06
+date: 2022-09-07
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 1c40770f1d14c..38b0399af6aeb 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: 2022-09-06
+date: 2022-09-07
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 9f81092cdb20a..d8f28e98bfe2b 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: 2022-09-06
+date: 2022-09-07
tags: ['contributor', 'dev', 'apidocs', 'kibana', '@kbn/optimizer-webpack-helpers']
---
import kbnOptimizerWebpackHelpersObj from './kbn_optimizer_webpack_helpers.devdocs.json';
diff --git a/api_docs/kbn_performance_testing_dataset_extractor.mdx b/api_docs/kbn_performance_testing_dataset_extractor.mdx
index dae280868ba9d..3b244a71ea63d 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: 2022-09-06
+date: 2022-09-07
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 1e780ff247591..09fbcf27b337b 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: 2022-09-06
+date: 2022-09-07
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 59df0a48f1476..b3d94adccca23 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: 2022-09-06
+date: 2022-09-07
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 4bf64e81a2cd1..5370accff1c66 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: 2022-09-06
+date: 2022-09-07
tags: ['contributor', 'dev', 'apidocs', 'kibana', '@kbn/react-field']
---
import kbnReactFieldObj from './kbn_react_field.devdocs.json';
diff --git a/api_docs/kbn_repo_source_classifier.mdx b/api_docs/kbn_repo_source_classifier.mdx
index e1b169cb11910..f7345d4477ff1 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: 2022-09-06
+date: 2022-09-07
tags: ['contributor', 'dev', 'apidocs', 'kibana', '@kbn/repo-source-classifier']
---
import kbnRepoSourceClassifierObj from './kbn_repo_source_classifier.devdocs.json';
diff --git a/api_docs/kbn_rule_data_utils.mdx b/api_docs/kbn_rule_data_utils.mdx
index c3e3fb68a1942..3b059008789cb 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: 2022-09-06
+date: 2022-09-07
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.mdx b/api_docs/kbn_securitysolution_autocomplete.mdx
index 594a90c6b992b..a31ad37a982b2 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: 2022-09-06
+date: 2022-09-07
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 d81e5aedca0cf..200f101ab449e 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: 2022-09-06
+date: 2022-09-07
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_hook_utils.mdx b/api_docs/kbn_securitysolution_hook_utils.mdx
index b368ae1b07744..b6b49cb579487 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: 2022-09-06
+date: 2022-09-07
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.mdx b/api_docs/kbn_securitysolution_io_ts_alerting_types.mdx
index 9ed642a17ac73..9089d14f4b003 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: 2022-09-06
+date: 2022-09-07
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.mdx b/api_docs/kbn_securitysolution_io_ts_list_types.mdx
index 86bfe88fc4aeb..bba947ac7e11b 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: 2022-09-06
+date: 2022-09-07
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.mdx b/api_docs/kbn_securitysolution_io_ts_types.mdx
index 03c96517daf9c..62be0bbfe48a3 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: 2022-09-06
+date: 2022-09-07
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 216e8655b5bb0..5d48b2224372c 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: 2022-09-06
+date: 2022-09-07
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.mdx b/api_docs/kbn_securitysolution_list_api.mdx
index e366c255b21bc..7d2ae7dc2d211 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: 2022-09-06
+date: 2022-09-07
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 e1668dae928e1..0b8838d8d67a4 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: 2022-09-06
+date: 2022-09-07
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.mdx b/api_docs/kbn_securitysolution_list_hooks.mdx
index 5ab603d10b235..da2773dd82341 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: 2022-09-06
+date: 2022-09-07
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.mdx b/api_docs/kbn_securitysolution_list_utils.mdx
index 0df64a065cf26..06d395a982f53 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: 2022-09-06
+date: 2022-09-07
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 9bd7ba6ecdcf1..9c0177542408b 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: 2022-09-06
+date: 2022-09-07
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 82de3d9623a24..135eacc8a0aba 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: 2022-09-06
+date: 2022-09-07
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 1a77dd0e57e72..e9d72aca33d1b 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: 2022-09-06
+date: 2022-09-07
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 22436ed83b27a..daec0fbafebba 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: 2022-09-06
+date: 2022-09-07
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 2c098b0e95e53..7caae7be65b1c 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: 2022-09-06
+date: 2022-09-07
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 b5873d6efc302..eb2b36a093419 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: 2022-09-06
+date: 2022-09-07
tags: ['contributor', 'dev', 'apidocs', 'kibana', '@kbn/shared-svg']
---
import kbnSharedSvgObj from './kbn_shared_svg.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 1b9969731fe0b..64ee09c6778d1 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: 2022-09-06
+date: 2022-09-07
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 4ddd242dcd879..e71fbfcc5e32e 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: 2022-09-06
+date: 2022-09-07
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.mdx b/api_docs/kbn_shared_ux_card_no_data.mdx
index 2dbf643ce259a..c6517d1be1a1b 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: 2022-09-06
+date: 2022-09-07
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 1c61826eb8bf3..ce09ae2ea9c5f 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: 2022-09-06
+date: 2022-09-07
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_link_redirect_app_mocks.mdx b/api_docs/kbn_shared_ux_link_redirect_app_mocks.mdx
index 8403639e1224a..b0c7ea475d617 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: 2022-09-06
+date: 2022-09-07
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_page_analytics_no_data.mdx b/api_docs/kbn_shared_ux_page_analytics_no_data.mdx
index a40c2bfb5fcc4..5589729df6e7e 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: 2022-09-06
+date: 2022-09-07
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 f01fa624748e0..dd09c3dc356fc 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: 2022-09-06
+date: 2022-09-07
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 31f22196e83bb..c0ec200897412 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: 2022-09-06
+date: 2022-09-07
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 656be2f5e1328..2219b1673161e 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: 2022-09-06
+date: 2022-09-07
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 b60be077512db..25aba49a423f0 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: 2022-09-06
+date: 2022-09-07
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 9fd3f5c108992..9d22ea10ba60e 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: 2022-09-06
+date: 2022-09-07
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 3741a45a23382..130b3f49f7b49 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: 2022-09-06
+date: 2022-09-07
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 e4b72077198fd..7d23c47cc4602 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: 2022-09-06
+date: 2022-09-07
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 d23bd9668426f..0792196115fb6 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: 2022-09-06
+date: 2022-09-07
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 eefd75b0fb7fa..fcddeb97badf4 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: 2022-09-06
+date: 2022-09-07
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 df1fc4d91ed90..a58549e515ab0 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: 2022-09-06
+date: 2022-09-07
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 a1aa6cb442150..05e2e8a8fd607 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: 2022-09-06
+date: 2022-09-07
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 1895906126c41..9454edf932fc9 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: 2022-09-06
+date: 2022-09-07
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_storybook_config.mdx b/api_docs/kbn_shared_ux_storybook_config.mdx
index d40071304bae9..f59cc2990735b 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: 2022-09-06
+date: 2022-09-07
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 3c001308fa58e..f4fa46e148800 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: 2022-09-06
+date: 2022-09-07
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 8ba8bdc804263..101e39460dd39 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: 2022-09-06
+date: 2022-09-07
tags: ['contributor', 'dev', 'apidocs', 'kibana', '@kbn/shared-ux-utility']
---
import kbnSharedUxUtilityObj from './kbn_shared_ux_utility.devdocs.json';
diff --git a/api_docs/kbn_some_dev_log.mdx b/api_docs/kbn_some_dev_log.mdx
index 4ec7116e43707..bfdd757376a36 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: 2022-09-06
+date: 2022-09-07
tags: ['contributor', 'dev', 'apidocs', 'kibana', '@kbn/some-dev-log']
---
import kbnSomeDevLogObj from './kbn_some_dev_log.devdocs.json';
diff --git a/api_docs/kbn_sort_package_json.mdx b/api_docs/kbn_sort_package_json.mdx
index bf751e78e2f42..e5ba136cbd881 100644
--- a/api_docs/kbn_sort_package_json.mdx
+++ b/api_docs/kbn_sort_package_json.mdx
@@ -8,7 +8,7 @@ slug: /kibana-dev-docs/api/kbn-sort-package-json
title: "@kbn/sort-package-json"
image: https://source.unsplash.com/400x175/?github
description: API docs for the @kbn/sort-package-json plugin
-date: 2022-09-06
+date: 2022-09-07
tags: ['contributor', 'dev', 'apidocs', 'kibana', '@kbn/sort-package-json']
---
import kbnSortPackageJsonObj from './kbn_sort_package_json.devdocs.json';
diff --git a/api_docs/kbn_std.mdx b/api_docs/kbn_std.mdx
index c6865cb9a191d..a0afadc32c950 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: 2022-09-06
+date: 2022-09-07
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 c72f3c4e12baa..e9d27d5fa7f3c 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: 2022-09-06
+date: 2022-09-07
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 f84cf0d75648c..7da16a7a86db4 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: 2022-09-06
+date: 2022-09-07
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 e82baeab81cb9..81a19853a94e8 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: 2022-09-06
+date: 2022-09-07
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 8a6da75a7fb10..a60e0bb196539 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: 2022-09-06
+date: 2022-09-07
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 ce97704328c60..0017ab4847b7a 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: 2022-09-06
+date: 2022-09-07
tags: ['contributor', 'dev', 'apidocs', 'kibana', '@kbn/test-jest-helpers']
---
import kbnTestJestHelpersObj from './kbn_test_jest_helpers.devdocs.json';
diff --git a/api_docs/kbn_tooling_log.mdx b/api_docs/kbn_tooling_log.mdx
index b8e011b54f342..1c8a69ed3e281 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: 2022-09-06
+date: 2022-09-07
tags: ['contributor', 'dev', 'apidocs', 'kibana', '@kbn/tooling-log']
---
import kbnToolingLogObj from './kbn_tooling_log.devdocs.json';
diff --git a/api_docs/kbn_type_summarizer.mdx b/api_docs/kbn_type_summarizer.mdx
index b4ebcfae7c4b6..9097c0e23934f 100644
--- a/api_docs/kbn_type_summarizer.mdx
+++ b/api_docs/kbn_type_summarizer.mdx
@@ -8,7 +8,7 @@ slug: /kibana-dev-docs/api/kbn-type-summarizer
title: "@kbn/type-summarizer"
image: https://source.unsplash.com/400x175/?github
description: API docs for the @kbn/type-summarizer plugin
-date: 2022-09-06
+date: 2022-09-07
tags: ['contributor', 'dev', 'apidocs', 'kibana', '@kbn/type-summarizer']
---
import kbnTypeSummarizerObj from './kbn_type_summarizer.devdocs.json';
diff --git a/api_docs/kbn_type_summarizer_core.mdx b/api_docs/kbn_type_summarizer_core.mdx
index 8795b16250a89..d25870a0246af 100644
--- a/api_docs/kbn_type_summarizer_core.mdx
+++ b/api_docs/kbn_type_summarizer_core.mdx
@@ -8,7 +8,7 @@ slug: /kibana-dev-docs/api/kbn-type-summarizer-core
title: "@kbn/type-summarizer-core"
image: https://source.unsplash.com/400x175/?github
description: API docs for the @kbn/type-summarizer-core plugin
-date: 2022-09-06
+date: 2022-09-07
tags: ['contributor', 'dev', 'apidocs', 'kibana', '@kbn/type-summarizer-core']
---
import kbnTypeSummarizerCoreObj from './kbn_type_summarizer_core.devdocs.json';
diff --git a/api_docs/kbn_typed_react_router_config.mdx b/api_docs/kbn_typed_react_router_config.mdx
index 5b8d2b1d3f0d9..ca24832d39054 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: 2022-09-06
+date: 2022-09-07
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_theme.mdx b/api_docs/kbn_ui_theme.mdx
index fc4fb9e4375b1..da182a99b439a 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: 2022-09-06
+date: 2022-09-07
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 f1dc37b46d564..84ee7c476dc62 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: 2022-09-06
+date: 2022-09-07
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 fa7f7a31f609e..8b67a2571449f 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: 2022-09-06
+date: 2022-09-07
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 5a54f093e2c65..72ca020a5f4f1 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: 2022-09-06
+date: 2022-09-07
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 d7647c5a47b79..9a2fbe1f4d7ca 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: 2022-09-06
+date: 2022-09-07
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 dbf3b91292d90..65de5938deab3 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: 2022-09-06
+date: 2022-09-07
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 c0cb483b562e5..0b5043451d275 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: 2022-09-06
+date: 2022-09-07
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 97fc5e134eb0f..2d0d88900d328 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: 2022-09-06
+date: 2022-09-07
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 a5b160dcf1979..f0691151cb965 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: 2022-09-06
+date: 2022-09-07
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 c5387dea37792..8c332abad5bed 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: 2022-09-06
+date: 2022-09-07
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 cdb2181234b5f..acd735588a62a 100644
--- a/api_docs/lens.devdocs.json
+++ b/api_docs/lens.devdocs.json
@@ -6992,6 +6992,19 @@
"path": "x-pack/plugins/lens/public/visualizations/xy/types.ts",
"deprecated": false
},
+ {
+ "parentPluginId": "lens",
+ "id": "def-public.XYState.showCurrentTimeMarker",
+ "type": "CompoundType",
+ "tags": [],
+ "label": "showCurrentTimeMarker",
+ "description": [],
+ "signature": [
+ "boolean | undefined"
+ ],
+ "path": "x-pack/plugins/lens/public/visualizations/xy/types.ts",
+ "deprecated": false
+ },
{
"parentPluginId": "lens",
"id": "def-public.XYState.valuesInLegend",
diff --git a/api_docs/lens.mdx b/api_docs/lens.mdx
index 698fa35e0d4e7..2dfde28af2161 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: 2022-09-06
+date: 2022-09-07
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-vis-editors)
| Public API count | Any count | Items lacking comments | Missing exports |
|-------------------|-----------|------------------------|-----------------|
-| 613 | 0 | 527 | 41 |
+| 614 | 0 | 528 | 41 |
## Client
diff --git a/api_docs/license_api_guard.mdx b/api_docs/license_api_guard.mdx
index affc63ce331b1..4d267c33db797 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: 2022-09-06
+date: 2022-09-07
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 2fcd6102f5a7a..61284932210e8 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: 2022-09-06
+date: 2022-09-07
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 e126958e9e916..736cddb1ca229 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: 2022-09-06
+date: 2022-09-07
tags: ['contributor', 'dev', 'apidocs', 'kibana', 'licensing']
---
import licensingObj from './licensing.devdocs.json';
diff --git a/api_docs/lists.mdx b/api_docs/lists.mdx
index 962b40fc27f97..b031f5b679f4a 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: 2022-09-06
+date: 2022-09-07
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 7a99638b5be97..1787ac033b8b5 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: 2022-09-06
+date: 2022-09-07
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 7e3a9628185ef..a73a0401d6142 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: 2022-09-06
+date: 2022-09-07
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 b7f0a7655b847..a9d2f93cef675 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: 2022-09-06
+date: 2022-09-07
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 35712c23b478a..d1fbb181e15aa 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: 2022-09-06
+date: 2022-09-07
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 ca77b7a91a941..10913f2ef46e9 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: 2022-09-06
+date: 2022-09-07
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 731ab5cc22e25..8841940f62ac3 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: 2022-09-06
+date: 2022-09-07
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 f23f4b5e01d53..1bd801357416c 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: 2022-09-06
+date: 2022-09-07
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 21c8675a744b8..ce8ecaf12b964 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: 2022-09-06
+date: 2022-09-07
tags: ['contributor', 'dev', 'apidocs', 'kibana', 'newsfeed']
---
import newsfeedObj from './newsfeed.devdocs.json';
diff --git a/api_docs/observability.devdocs.json b/api_docs/observability.devdocs.json
index 514e9d2af0390..79a9810bbeb51 100644
--- a/api_docs/observability.devdocs.json
+++ b/api_docs/observability.devdocs.json
@@ -7122,6 +7122,25 @@
"path": "x-pack/plugins/observability/server/routes/types.ts",
"deprecated": false
},
+ {
+ "parentPluginId": "observability",
+ "id": "def-server.ObservabilityRouteHandlerResources.spacesService",
+ "type": "Object",
+ "tags": [],
+ "label": "spacesService",
+ "description": [],
+ "signature": [
+ {
+ "pluginId": "spaces",
+ "scope": "server",
+ "docId": "kibSpacesPluginApi",
+ "section": "def-server.SpacesServiceStart",
+ "text": "SpacesServiceStart"
+ }
+ ],
+ "path": "x-pack/plugins/observability/server/routes/types.ts",
+ "deprecated": false
+ },
{
"parentPluginId": "observability",
"id": "def-server.ObservabilityRouteHandlerResources.request",
@@ -7263,6 +7282,8 @@
"<\"POST /api/observability/slos\", ",
"TypeC",
"<{ body: ",
+ "IntersectionC",
+ "<[",
"TypeC",
"<{ name: ",
"StringC",
@@ -7360,7 +7381,13 @@
"TypeC",
"<{ target: ",
"NumberC",
- "; }>; }>; }>, ",
+ "; }>; }>, ",
+ "PartialC",
+ "<{ settings: ",
+ "PartialC",
+ "<{ destination_index: ",
+ "StringC",
+ "; }>; }>]>; }>, ",
{
"pluginId": "observability",
"scope": "server",
@@ -7422,7 +7449,7 @@
"label": "ObservabilityConfig",
"description": [],
"signature": [
- "{ readonly unsafe: Readonly<{} & { slo: Readonly<{} & { enabled: boolean; }>; }>; readonly annotations: Readonly<{} & { index: string; enabled: boolean; }>; }"
+ "{ readonly unsafe: Readonly<{} & { slo: Readonly<{} & { enabled: boolean; }>; alertDetails: Readonly<{} & { enabled: boolean; }>; }>; readonly annotations: Readonly<{} & { index: string; enabled: boolean; }>; }"
],
"path": "x-pack/plugins/observability/server/index.ts",
"deprecated": false,
@@ -7441,6 +7468,8 @@
"<\"POST /api/observability/slos\", ",
"TypeC",
"<{ body: ",
+ "IntersectionC",
+ "<[",
"TypeC",
"<{ name: ",
"StringC",
@@ -7538,7 +7567,13 @@
"TypeC",
"<{ target: ",
"NumberC",
- "; }>; }>; }>, ",
+ "; }>; }>, ",
+ "PartialC",
+ "<{ settings: ",
+ "PartialC",
+ "<{ destination_index: ",
+ "StringC",
+ "; }>; }>]>; }>, ",
{
"pluginId": "observability",
"scope": "server",
diff --git a/api_docs/observability.mdx b/api_docs/observability.mdx
index fac3ee5ab3c80..6c8a1403db725 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: 2022-09-06
+date: 2022-09-07
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 |
|-------------------|-----------|------------------------|-----------------|
-| 396 | 2 | 393 | 30 |
+| 397 | 2 | 394 | 30 |
## Client
diff --git a/api_docs/osquery.mdx b/api_docs/osquery.mdx
index 963eda18fc357..6ed5b1a6acec5 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: 2022-09-06
+date: 2022-09-07
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 4406258c16647..8fb222863c65f 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: 2022-09-06
+date: 2022-09-07
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 |
|--------------|----------|------------------------|
-| 442 | 368 | 36 |
+| 444 | 369 | 36 |
### Public API health stats
| API Count | Any Count | Missing comments | Missing exports |
|--------------|----------|-----------------|--------|
-| 30558 | 180 | 20413 | 972 |
+| 30563 | 180 | 20418 | 973 |
## Plugin Directory
@@ -31,7 +31,7 @@ tags: ['contributor', 'dev', 'apidocs', 'kibana']
| | [Kibana Core](https://github.com/orgs/elastic/teams/kibana-core) | - | 23 | 0 | 19 | 1 |
| | [Machine Learning UI](https://github.com/orgs/elastic/teams/ml-ui) | AIOps plugin maintained by ML team. | 9 | 0 | 0 | 1 |
| | [Response Ops](https://github.com/orgs/elastic/teams/response-ops) | - | 368 | 0 | 359 | 21 |
-| | [APM UI](https://github.com/orgs/elastic/teams/apm-ui) | The user interface for Elastic APM | 39 | 0 | 39 | 53 |
+| | [APM UI](https://github.com/orgs/elastic/teams/apm-ui) | The user interface for Elastic APM | 39 | 0 | 39 | 54 |
| | [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. | 80 | 1 | 71 | 2 |
| | [Kibana Presentation](https://github.com/orgs/elastic/teams/kibana-presentation) | Adds Canvas application to Kibana | 9 | 0 | 8 | 3 |
@@ -99,7 +99,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) | - | 615 | 3 | 418 | 9 |
| | [Security Team](https://github.com/orgs/elastic/teams/security-team) | - | 3 | 0 | 3 | 1 |
-| | [Vis Editors](https://github.com/orgs/elastic/teams/kibana-vis-editors) | 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. | 613 | 0 | 527 | 41 |
+| | [Vis Editors](https://github.com/orgs/elastic/teams/kibana-vis-editors) | 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. | 614 | 0 | 528 | 41 |
| | [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 |
@@ -113,7 +113,7 @@ tags: ['contributor', 'dev', 'apidocs', 'kibana']
| | [Stack Monitoring](https://github.com/orgs/elastic/teams/stack-monitoring-ui) | - | 9 | 0 | 9 | 0 |
| | [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 |
-| | [Observability UI](https://github.com/orgs/elastic/teams/observability-ui) | - | 396 | 2 | 393 | 30 |
+| | [Observability UI](https://github.com/orgs/elastic/teams/observability-ui) | - | 397 | 2 | 394 | 30 |
| | [Security asset management](https://github.com/orgs/elastic/teams/security-asset-management) | - | 13 | 0 | 13 | 0 |
| 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). | 243 | 2 | 187 | 12 |
@@ -189,7 +189,7 @@ tags: ['contributor', 'dev', 'apidocs', 'kibana']
| | Kibana Core | - | 18 | 0 | 0 | 0 |
| | Kibana Core | - | 20 | 0 | 0 | 0 |
| | [Owner missing] | - | 16 | 0 | 16 | 0 |
-| | [Owner missing] | Elastic APM trace data generator | 75 | 0 | 75 | 12 |
+| | [Owner missing] | Elastic APM trace data generator | 76 | 0 | 76 | 12 |
| | [Owner missing] | - | 11 | 0 | 11 | 0 |
| | [Owner missing] | - | 10 | 0 | 10 | 0 |
| | [Owner missing] | - | 76 | 0 | 76 | 0 |
@@ -288,6 +288,7 @@ tags: ['contributor', 'dev', 'apidocs', 'kibana']
| | Kibana Core | - | 3 | 0 | 3 | 0 |
| | Kibana Core | - | 5 | 0 | 0 | 0 |
| | Kibana Core | - | 6 | 0 | 6 | 0 |
+| | Kibana Core | - | 2 | 0 | 2 | 0 |
| | Kibana Core | - | 94 | 1 | 66 | 0 |
| | Kibana Core | - | 289 | 1 | 126 | 0 |
| | Kibana Core | - | 68 | 0 | 49 | 0 |
diff --git a/api_docs/presentation_util.mdx b/api_docs/presentation_util.mdx
index 7fb55d6a2ea42..a2d91355724e8 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: 2022-09-06
+date: 2022-09-07
tags: ['contributor', 'dev', 'apidocs', 'kibana', 'presentationUtil']
---
import presentationUtilObj from './presentation_util.devdocs.json';
diff --git a/api_docs/remote_clusters.mdx b/api_docs/remote_clusters.mdx
index 06e4c7b534cd6..514397f4332c4 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: 2022-09-06
+date: 2022-09-07
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 eda4e337d214e..da316fb620860 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: 2022-09-06
+date: 2022-09-07
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 74411201bbdbe..8e403ed011cdc 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: 2022-09-06
+date: 2022-09-07
tags: ['contributor', 'dev', 'apidocs', 'kibana', 'rollup']
---
import rollupObj from './rollup.devdocs.json';
diff --git a/api_docs/rule_registry.mdx b/api_docs/rule_registry.mdx
index 528417dce9da8..9c1bdbf4b9f86 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: 2022-09-06
+date: 2022-09-07
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 3e74986c45337..0e9a085aceb39 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: 2022-09-06
+date: 2022-09-07
tags: ['contributor', 'dev', 'apidocs', 'kibana', 'runtimeFields']
---
import runtimeFieldsObj from './runtime_fields.devdocs.json';
diff --git a/api_docs/saved_objects.mdx b/api_docs/saved_objects.mdx
index 0728273a80d40..fb7725b09955a 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: 2022-09-06
+date: 2022-09-07
tags: ['contributor', 'dev', 'apidocs', 'kibana', 'savedObjects']
---
import savedObjectsObj from './saved_objects.devdocs.json';
diff --git a/api_docs/saved_objects_finder.mdx b/api_docs/saved_objects_finder.mdx
index 1dddbeff870f6..3331a1cd1d67d 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: 2022-09-06
+date: 2022-09-07
tags: ['contributor', 'dev', 'apidocs', 'kibana', 'savedObjectsFinder']
---
import savedObjectsFinderObj from './saved_objects_finder.devdocs.json';
diff --git a/api_docs/saved_objects_management.mdx b/api_docs/saved_objects_management.mdx
index 0257e69849de6..3f6aa6aea4603 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: 2022-09-06
+date: 2022-09-07
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 12c1c41dcf350..20f8bf584aee3 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: 2022-09-06
+date: 2022-09-07
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 5c3b22b466476..9913bdfb6eea6 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: 2022-09-06
+date: 2022-09-07
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 be9ec295c6f89..a76dc1e07c80f 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: 2022-09-06
+date: 2022-09-07
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 c866e4461df0d..fa3ef4253b26f 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: 2022-09-06
+date: 2022-09-07
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 55e225c99929f..c13960d63da4d 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: 2022-09-06
+date: 2022-09-07
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 b47390e54e629..2345b3fc39c9a 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: 2022-09-06
+date: 2022-09-07
tags: ['contributor', 'dev', 'apidocs', 'kibana', 'security']
---
import securityObj from './security.devdocs.json';
diff --git a/api_docs/security_solution.mdx b/api_docs/security_solution.mdx
index 11192512cb016..94abe987c266d 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: 2022-09-06
+date: 2022-09-07
tags: ['contributor', 'dev', 'apidocs', 'kibana', 'securitySolution']
---
import securitySolutionObj from './security_solution.devdocs.json';
diff --git a/api_docs/session_view.mdx b/api_docs/session_view.mdx
index b8fbf49f5f14c..40b7eb80a0859 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: 2022-09-06
+date: 2022-09-07
tags: ['contributor', 'dev', 'apidocs', 'kibana', 'sessionView']
---
import sessionViewObj from './session_view.devdocs.json';
diff --git a/api_docs/share.mdx b/api_docs/share.mdx
index e3cd4dcce6ed8..0027dfe8d1a38 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: 2022-09-06
+date: 2022-09-07
tags: ['contributor', 'dev', 'apidocs', 'kibana', 'share']
---
import shareObj from './share.devdocs.json';
diff --git a/api_docs/snapshot_restore.mdx b/api_docs/snapshot_restore.mdx
index 8543671e08df9..23975075d9454 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: 2022-09-06
+date: 2022-09-07
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 03127a254c900..83bfab4e72942 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: 2022-09-06
+date: 2022-09-07
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 ed9f4c13f94fa..cb3f5b3db0061 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: 2022-09-06
+date: 2022-09-07
tags: ['contributor', 'dev', 'apidocs', 'kibana', 'stackAlerts']
---
import stackAlertsObj from './stack_alerts.devdocs.json';
diff --git a/api_docs/task_manager.mdx b/api_docs/task_manager.mdx
index dc22930eb237c..f1fe863db08b7 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: 2022-09-06
+date: 2022-09-07
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 a1601dcf08d76..394fa389290e9 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: 2022-09-06
+date: 2022-09-07
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 8fc5e8ef87ee2..f3bd907ce22dd 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: 2022-09-06
+date: 2022-09-07
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 7edfe584d3398..0a81e2cc07c4d 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: 2022-09-06
+date: 2022-09-07
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 3a3e106eed4f5..0cf966b634b7c 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: 2022-09-06
+date: 2022-09-07
tags: ['contributor', 'dev', 'apidocs', 'kibana', 'telemetryManagementSection']
---
import telemetryManagementSectionObj from './telemetry_management_section.devdocs.json';
diff --git a/api_docs/threat_intelligence.mdx b/api_docs/threat_intelligence.mdx
index 8c3375cd9adc8..011ea8d0d95ab 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: 2022-09-06
+date: 2022-09-07
tags: ['contributor', 'dev', 'apidocs', 'kibana', 'threatIntelligence']
---
import threatIntelligenceObj from './threat_intelligence.devdocs.json';
diff --git a/api_docs/timelines.mdx b/api_docs/timelines.mdx
index 0a3686d2ae196..8dae68398be5e 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: 2022-09-06
+date: 2022-09-07
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 a0cfa085f84e9..b794c5c014de0 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: 2022-09-06
+date: 2022-09-07
tags: ['contributor', 'dev', 'apidocs', 'kibana', 'transform']
---
import transformObj from './transform.devdocs.json';
diff --git a/api_docs/triggers_actions_ui.mdx b/api_docs/triggers_actions_ui.mdx
index 040b336530148..2992905d08c2d 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: 2022-09-06
+date: 2022-09-07
tags: ['contributor', 'dev', 'apidocs', 'kibana', 'triggersActionsUi']
---
import triggersActionsUiObj from './triggers_actions_ui.devdocs.json';
diff --git a/api_docs/ui_actions.mdx b/api_docs/ui_actions.mdx
index 4070f5232d118..e616cd4f4cea1 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: 2022-09-06
+date: 2022-09-07
tags: ['contributor', 'dev', 'apidocs', 'kibana', 'uiActions']
---
import uiActionsObj from './ui_actions.devdocs.json';
diff --git a/api_docs/ui_actions_enhanced.mdx b/api_docs/ui_actions_enhanced.mdx
index cb114687d6f1f..6b6005a4b6dc2 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: 2022-09-06
+date: 2022-09-07
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 a40b2083ff429..086e4e4fdfa1c 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: 2022-09-06
+date: 2022-09-07
tags: ['contributor', 'dev', 'apidocs', 'kibana', 'unifiedFieldList']
---
import unifiedFieldListObj from './unified_field_list.devdocs.json';
diff --git a/api_docs/unified_search.mdx b/api_docs/unified_search.mdx
index 5a83d305fdb9d..2987c084a54a2 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: 2022-09-06
+date: 2022-09-07
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 ca5d1fd443820..a8fd92525c5db 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: 2022-09-06
+date: 2022-09-07
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 db92454641100..1c2f622fecd29 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: 2022-09-06
+date: 2022-09-07
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 6d198b48f1535..9749547dcd8b5 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: 2022-09-06
+date: 2022-09-07
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 b1eb48b0c600d..ccdad23728da6 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: 2022-09-06
+date: 2022-09-07
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 25047939fe057..ef7c321c20a94 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: 2022-09-06
+date: 2022-09-07
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 083de23429f5a..4fa1efe9dd5ce 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: 2022-09-06
+date: 2022-09-07
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 0d34ed2680ec6..66c145e6cbbf8 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: 2022-09-06
+date: 2022-09-07
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 2de4de83b5c9e..dc124a90e3097 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: 2022-09-06
+date: 2022-09-07
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 c826aba082e91..1295a090b2e3a 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: 2022-09-06
+date: 2022-09-07
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 13db8ee610d41..b91b9bddda3c1 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: 2022-09-06
+date: 2022-09-07
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 a44a9f88effb6..27042f1122f70 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: 2022-09-06
+date: 2022-09-07
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 fac57b166ef54..10a8dda9c980f 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: 2022-09-06
+date: 2022-09-07
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 b6fe855de9250..0d2d7576f2bcd 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: 2022-09-06
+date: 2022-09-07
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 adc7b920f08a3..0db3e646e0ddf 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: 2022-09-06
+date: 2022-09-07
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 9fc1b40590470..44eaeaf3d77a8 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: 2022-09-06
+date: 2022-09-07
tags: ['contributor', 'dev', 'apidocs', 'kibana', 'visualizations']
---
import visualizationsObj from './visualizations.devdocs.json';
diff --git a/docs/management/action-types.asciidoc b/docs/management/action-types.asciidoc
index a3d6586e6e851..415080c12a65f 100644
--- a/docs/management/action-types.asciidoc
+++ b/docs/management/action-types.asciidoc
@@ -71,25 +71,24 @@ a| <>
[NOTE]
==============================================
Some connector types are paid commercial features, while others are free.
-For a comparison of the Elastic subscription levels,
-see {subscriptions}[the subscription page].
+For a comparison of the Elastic subscription levels, go to
+{subscriptions}[the subscription page].
==============================================
[float]
[[connector-management]]
-=== Managing Connectors
+=== Managing connectors
-Rules use *Connectors* to route actions to different destinations like log files, ticketing systems, and messaging tools. While each {kib} app can offer their own types of rules, they typically share connectors. The *Connectors* tab offers a central place to view and manage all the connectors in the current space.
-
-For more information on connectors and the types of actions available see <>.
+Rules use connectors to route actions to different destinations like log files, ticketing systems, and messaging tools. While each {kib} app can offer their own types of rules, they typically share connectors. The *Connectors* tab offers a central place to view and manage all the connectors in the current space.
[role="screenshot"]
-image::images/connector-listing.png[Example connector listing in the Rules and Connectors UI]
+image::images/connector-listing.png[Example connector listing in the {rules-ui} UI]
[float]
=== Required permissions
-Access to connectors is granted based on your privileges to alerting-enabled features. See <> for more information.
+Access to connectors is granted based on your privileges to alerting-enabled
+features. For more information, go to <>.
[float]
=== Connector networking configuration
@@ -100,18 +99,15 @@ Use the <> to customize connecto
[[connectors-list]]
=== Connector list
-The *Connectors* tab lists all connectors in the current space. The *search bar* can be used to find specific connectors by name and/or type.
-
-[role="screenshot"]
-image::images/connector-filter-by-search.png[Filtering the connector list using the search bar]
-
-
-The *type* dropdown also lets you filter to a subset of connector types.
+The *Connectors* tab lists all connectors in the current space. The search bar
+can be used to find specific connectors by name and type. The *Type* dropdown
+also enables you to filter to a subset of connector types.
[role="screenshot"]
image::images/connector-filter-by-type.png[Filtering the connector list by types of connectors]
-You can delete individual connectors using the trash icon. Connectors can also be deleted in bulk by multi-selecting them and clicking the *Delete* button to the left of the search box.
+You can delete individual connectors using the trash icon. Alternatively, select
+multiple connectors and delete them in bulk using the *Delete* button.
[role="screenshot"]
image::images/connector-delete.png[Deleting connectors individually or in bulk]
@@ -119,28 +115,35 @@ image::images/connector-delete.png[Deleting connectors individually or in bulk]
[NOTE]
============================================================================
You can delete a connector even if there are still actions referencing it.
-When this happens the action will fail to execute, and appear as errors in the {kib} logs.
+When this happens the action will fail to run and errors appear in the {kib} logs.
============================================================================
[float]
[[creating-new-connector]]
=== Creating a new connector
-New connectors can be created by clicking the *Create connector* button, which will guide you to select the type of connector and configure its properties. Refer to <> for the types of connectors available and how to configure them. Once you create a connector it will be made available to you anytime you set up an action in the current space.
+New connectors can be created with the *Create connector* button, which guides
+you to select the type of connector and configure its properties.
[role="screenshot"]
image::images/connector-select-type.png[Connector select type]
+After you create a connector, it is available for use any time you set up an
+action in the current space.
+
[float]
[[importing-and-exporting-connectors]]
=== Importing and exporting connectors
-To import and export connectors, use the <>.
-After a successful import, the proper banner is displayed:
+To import and export connectors, use the
+<>.
+
[role="screenshot"]
-image::images/coonectors-import-banner.png[Connectors import banner, width=50%]
+image::images/connectors-import-banner.png[Connectors import banner, width=50%]
+
+If a connector is missing sensitive information after the import, a **Fix**
+button appears in *{rules-ui}*.
-If a connector is missing user sensitive information because of the import, a **Fix** button appears in the list view.
[role="screenshot"]
image::images/connectors-with-missing-secrets.png[Connectors with missing secrets]
@@ -156,7 +159,7 @@ before {kib} starts.
=== Monitoring connectors
The <> helps you understand the performance of all tasks in your environment.
-However, if connectors fail to execute, they will report as successful to Task Manager. The failure stats will not
+However, if connectors fail to run, they will report as successful to Task Manager. The failure stats will not
accurately depict the performance of connectors.
For more information on connector successes and failures, refer to the <>.
diff --git a/docs/management/connectors/images/connector-delete.png b/docs/management/connectors/images/connector-delete.png
index ccb6bcea4bade..2e0e5d8a06b25 100644
Binary files a/docs/management/connectors/images/connector-delete.png and b/docs/management/connectors/images/connector-delete.png differ
diff --git a/docs/management/connectors/images/connector-filter-by-search.png b/docs/management/connectors/images/connector-filter-by-search.png
deleted file mode 100644
index 97348e70d91b3..0000000000000
Binary files a/docs/management/connectors/images/connector-filter-by-search.png and /dev/null differ
diff --git a/docs/management/connectors/images/connector-filter-by-type.png b/docs/management/connectors/images/connector-filter-by-type.png
index b95ef4e1a2e3e..c09a285d2af9c 100644
Binary files a/docs/management/connectors/images/connector-filter-by-type.png and b/docs/management/connectors/images/connector-filter-by-type.png differ
diff --git a/docs/management/connectors/images/connector-listing.png b/docs/management/connectors/images/connector-listing.png
index 68a529e16aa76..e7fb0899ef4a7 100644
Binary files a/docs/management/connectors/images/connector-listing.png and b/docs/management/connectors/images/connector-listing.png differ
diff --git a/docs/management/connectors/images/connector-select-type.png b/docs/management/connectors/images/connector-select-type.png
index ef5825b149311..90f26778dd957 100644
Binary files a/docs/management/connectors/images/connector-select-type.png and b/docs/management/connectors/images/connector-select-type.png differ
diff --git a/docs/management/connectors/images/connectors-import-banner.png b/docs/management/connectors/images/connectors-import-banner.png
new file mode 100644
index 0000000000000..92e4fe68d929d
Binary files /dev/null and b/docs/management/connectors/images/connectors-import-banner.png differ
diff --git a/docs/management/connectors/images/connectors-with-missing-secrets.png b/docs/management/connectors/images/connectors-with-missing-secrets.png
new file mode 100644
index 0000000000000..f4f2ba0d73e13
Binary files /dev/null and b/docs/management/connectors/images/connectors-with-missing-secrets.png differ
diff --git a/docs/management/images/connectors-with-missing-secrets.png b/docs/management/images/connectors-with-missing-secrets.png
deleted file mode 100644
index ffc902d4a4768..0000000000000
Binary files a/docs/management/images/connectors-with-missing-secrets.png and /dev/null differ
diff --git a/docs/management/images/coonectors-import-banner.png b/docs/management/images/coonectors-import-banner.png
deleted file mode 100644
index 55a6e91d28c8d..0000000000000
Binary files a/docs/management/images/coonectors-import-banner.png and /dev/null differ
diff --git a/docs/management/watcher-ui/index.asciidoc b/docs/management/watcher-ui/index.asciidoc
index 3523fc3a9fc14..c4e5ef928b9b0 100644
--- a/docs/management/watcher-ui/index.asciidoc
+++ b/docs/management/watcher-ui/index.asciidoc
@@ -225,6 +225,10 @@ simulation. Be aware of these implementation details on overrides:
* Condition overrides indicates if you want to force the condition to always be `true`.
* Action overrides support {ref}/watcher-api-execute-watch.html#watcher-api-execute-watch-action-mode[multiple options].
+Some watches, such as those using basic auth credentials, contain passwords. For security
+reasons, these passwords will be stripped from any watches that are loaded by the
+Watcher UI. You will need to manually re-enter these passwords to simulate the watch.
+
After starting the simulation, you’ll see a results screen. For more information
on the fields in the response, see the {ref}/watcher-api-execute-watch.html[Execute watch API].
diff --git a/docs/user/alerting/alerting-getting-started.asciidoc b/docs/user/alerting/alerting-getting-started.asciidoc
index ca0b8ff8ee111..708c4f0ddfeff 100644
--- a/docs/user/alerting/alerting-getting-started.asciidoc
+++ b/docs/user/alerting/alerting-getting-started.asciidoc
@@ -1,17 +1,15 @@
-[role="xpack"]
[[alerting-getting-started]]
= Alerting
-
--
Alerting allows you to define *rules* to detect complex conditions within different {kib} apps and trigger actions when those conditions are met. Alerting is integrated with {observability-guide}/create-alerts.html[*Observability*], {security-guide}/prebuilt-rules.html[*Security*], <> and {ml-docs}/ml-configuring-alerts.html[*{ml-app}*], can be centrally managed from the <> UI, and provides a set of built-in <> and <> (known as stack rules) for you to use.
-image::images/alerting-overview.png[Rules and Connectors UI]
+image::images/alerting-overview.png[{rules-ui} UI]
[IMPORTANT]
==============================================
-To make sure you can access alerting and actions, see the <> section.
+To make sure you can access alerting and actions, see the <> section.
==============================================
[float]
@@ -24,7 +22,7 @@ This section describes all of these elements and how they operate together.
[float]
=== Rules
-A rule specifies a background task that runs on the {kib} server to check for specific conditions. {kib} provides two types of rules: stack rules that are built into {kib} and the rules that are registered by Kibana apps. Refer to <> for more information.
+A rule specifies a background task that runs on the {kib} server to check for specific conditions. {kib} provides two types of rules: stack rules that are built into {kib} and the rules that are registered by {kib} apps. Refer to <> for more information.
A rule consists of three main parts:
@@ -46,7 +44,7 @@ The following sections describe each part of the rule in more detail.
[[alerting-concepts-conditions]]
==== Conditions
-Under the hood, {kib} rules detect conditions by running a Javascript function on the {kib} server, which gives it the flexibility to support a wide range of conditions, anything from the results of a simple {es} query to heavy computations involving data from multiple sources or external systems.
+Under the hood, {kib} rules detect conditions by running a JavaScript function on the {kib} server, which gives it the flexibility to support a wide range of conditions, anything from the results of a simple {es} query to heavy computations involving data from multiple sources or external systems.
These conditions are packaged and exposed as *rule types*. A rule type hides the underlying details of the condition, and exposes a set of parameters
to control the details of the conditions to detect.
@@ -123,9 +121,9 @@ image::images/rule-concepts-summary.svg[Rules, connectors, alerts and actions wo
[float]
[[alerting-concepts-differences]]
-== Differences from Watcher
+== Differences from {watcher}
-Alerting and <> are both used to detect conditions and can trigger actions in response, but they are completely independent alerting systems.
+Alerting and <> are both used to detect conditions and can trigger actions in response, but they are completely independent alerting systems.
This section will clarify some of the important differences in the function and intent of the two systems.
@@ -137,6 +135,6 @@ Functionally, Alerting differs in that:
* Actions are linked to *alerts* in Alerting. Actions are fired for each occurrence of a detected condition, rather than for the entire rule.
At a higher level, Alerting allows rich integrations across use cases like <>, <>, <>, and <>.
-Pre-packaged *rule types* simplify setup and hide the details of complex, domain-specific detections, while providing a consistent interface across {kib}.
+Prepackaged *rule types* simplify setup and hide the details of complex, domain-specific detections, while providing a consistent interface across {kib}.
--
diff --git a/docs/user/alerting/alerting-setup.asciidoc b/docs/user/alerting/alerting-setup.asciidoc
index c797620987996..819f20005d7a4 100644
--- a/docs/user/alerting/alerting-setup.asciidoc
+++ b/docs/user/alerting/alerting-setup.asciidoc
@@ -11,7 +11,7 @@ configuration.
[float]
[[alerting-prerequisites]]
=== Prerequisites
-If you are using an *on-premises* Elastic Stack deployment:
+If you are using an *on-premises* {stack} deployment:
* In the `kibana.yml` configuration file, add the
<>
@@ -19,7 +19,7 @@ setting.
* For emails to have a footer with a link back to {kib}, set the
<> configuration setting.
-If you are using an *on-premises* Elastic Stack deployment with
+If you are using an *on-premises* {stack} deployment with
<>:
* If you are unable to access {kib} {alert-features}, ensure that you have not
diff --git a/docs/user/alerting/alerting-troubleshooting.asciidoc b/docs/user/alerting/alerting-troubleshooting.asciidoc
index 32c77d7fa57a7..95c07fccf3b47 100644
--- a/docs/user/alerting/alerting-troubleshooting.asciidoc
+++ b/docs/user/alerting/alerting-troubleshooting.asciidoc
@@ -31,7 +31,7 @@ and Task Manager <>.
[float]
[[alerting-managment-detail]]
=== Using rules and connectors list for the current state and finding issues
-*Rules and Connectors* in *Stack Management* lists the rules and connectors available in the space you’re currently in. When you click a rule name, you are navigated to the <> for the rule, where you can see currently active alerts.
+*{rules-ui}* in *{stack-manage-app}* lists the rules and connectors available in the space you're currently in. When you click a rule name, you are navigated to the <> for the rule, where you can see currently active alerts.
The start date on this page indicates when a rule is triggered, and for what alerts. In addition, the duration of the condition indicates how long the instance is active.
[role="screenshot"]
image::images/rule-details-alerts-inactive.png[Alerting management details]
@@ -44,7 +44,9 @@ When creating or editing an index threshold rule, you see a graph of the data th
[role="screenshot"]
image::images/index-threshold-chart.png[Index Threshold chart]
-The end date is related to the rule interval (IIRC, 30 “intervals” worth of time). You can use this view to see if the rule is getting the data you expect, and visually compare to the threshold value (a horizontal line in the graph). If the graph does not contain any lines except for the threshold line, then the rule has an issue, for example, no data is available given the specified index and fields or there is a permission error.
+The end date is related to the rule interval.
+//(IIRC, 30 “intervals” worth of time)
+You can use this view to see if the rule is getting the data you expect, and visually compare to the threshold value (a horizontal line in the graph). If the graph does not contain any lines except for the threshold line, then the rule has an issue, for example, no data is available given the specified index and fields or there is a permission error.
Diagnosing these may be difficult - but there may be log messages for error conditions.
[float]
@@ -52,7 +54,7 @@ Diagnosing these may be difficult - but there may be log messages for error cond
=== Use the REST APIs
There is a rich set of HTTP endpoints to introspect and manage rules and connectors.
-One of the http endpoints available for actions is the POST <>. You can use this to “test” an action. For instance, if you have a server log action created, you can run it via curling the endpoint:
+One of the HTTP endpoints available for actions is the POST <>. You can use this to “test” an action. For instance, if you have a server log action created, you can run it via curling the endpoint:
[source, txt]
--------------------------------------------------
curl -X POST -k \
@@ -62,7 +64,7 @@ curl -X POST -k \
-d '{"params":{"subject":"hallo","message":"hallo!","to":["me@example.com"]}}'
--------------------------------------------------
-experimental[] In addition, there is a command-line client that uses legacy Rules and Connectors APIs, which can be easier to use, but must be updated for the new APIs.
+experimental[] In addition, there is a command-line client that uses legacy {rules-ui} APIs, which can be easier to use, but must be updated for the new APIs.
CLI tools to list, create, edit, and delete alerts (rules) and actions (connectors) are available in https://github.com/pmuellr/kbn-action[kbn-action], which you can install as follows:
[source, txt]
--------------------------------------------------
@@ -75,7 +77,7 @@ The same REST POST _execute API command will be:
kbn-action execute a692dc89-15b9-4a3c-9e47-9fb6872e49ce ‘{"params":{"subject":"hallo","message":"hallo!","to":["me@example.com"]}}’
--------------------------------------------------
-The result of this http request (and printed to stdout by https://github.com/pmuellr/kbn-action[kbn-action]) will be data returned by the action, along with error messages if errors were encountered.
+The result of this HTTP request (and printed to stdout by https://github.com/pmuellr/kbn-action[kbn-action]) will be data returned by the action, along with error messages if errors were encountered.
[float]
[[alerting-error-banners]]
diff --git a/docs/user/alerting/create-and-manage-rules.asciidoc b/docs/user/alerting/create-and-manage-rules.asciidoc
index 6f52ef632da99..a3af0d89164c8 100644
--- a/docs/user/alerting/create-and-manage-rules.asciidoc
+++ b/docs/user/alerting/create-and-manage-rules.asciidoc
@@ -10,7 +10,7 @@ central place to:
* <> rules
* <> including enabling/disabling, muting/unmuting, and deleting
-* Drill-down to <>
+* Drill down to <>
[role="screenshot"]
image:images/rules-and-connectors-ui.png[Example rule listing in {rules-ui}]
@@ -99,7 +99,7 @@ image::images/rule-flyout-general-details.png[alt='All rules have name, tags, ch
[[defining-rules-type-conditions]]
==== Rule type and conditions
-Depending upon the {kib} app and context, you might be prompted to choose the type of rule to create. Some apps will pre-select the type of rule for you.
+Depending upon the {kib} app and context, you might be prompted to choose the type of rule to create. Some apps will preselect the type of rule for you.
[role="screenshot"]
image::images/rule-flyout-rule-type-selection.png[Choosing the type of rule to create]
@@ -218,7 +218,7 @@ image::images/rules-imported-banner.png[Rules import banner, width=50%]
[float]
[[rule-details]]
-=== Drilldown to rule details
+=== Drill down to rule details
Select a rule name from the rule listing to access the *Rule details* page, which tells you about the state of the rule and provides granular control over the actions it is taking.
diff --git a/docs/user/alerting/images/rule-types-es-query-conditions.png b/docs/user/alerting/images/rule-types-es-query-conditions.png
index cfa5dcfcd1ca9..4bc5f4f61fc07 100644
Binary files a/docs/user/alerting/images/rule-types-es-query-conditions.png and b/docs/user/alerting/images/rule-types-es-query-conditions.png differ
diff --git a/docs/user/alerting/rule-types.asciidoc b/docs/user/alerting/rule-types.asciidoc
index 120c580330b9f..7aab91b27e030 100644
--- a/docs/user/alerting/rule-types.asciidoc
+++ b/docs/user/alerting/rule-types.asciidoc
@@ -2,8 +2,8 @@
[[rule-types]]
== Rule types
-A rule is a set of <>, <>, and <> that enable notifications. {kib} provides rules built into the Elastic Stack and rules registered by one of the {kib} apps.
-You can create most rules types in < Rules and Connectors>>. For information on creating security rules, refer to {security-guide}/rules-ui-create.html[Create a detection rule].
+A rule is a set of <>, <>, and <> that enable notifications. {kib} provides rules built into the {stack} and rules registered by one of the {kib} apps.
+You can create most rules types in < {rules-ui}>>. For information on creating security rules, refer to {security-guide}/rules-ui-create.html[Create a detection rule].
[NOTE]
==============================================
@@ -37,9 +37,9 @@ see {subscriptions}[the subscription page].
[float]
[[observability-rules]]
-=== Observability rules
+=== {observability} rules
-Observability rules are categorized into APM and User Experience, Logs, Metrics, Stack Monitoring, and Uptime.
+{observability} rules are categorized into APM and {user-experience}, Logs, Metrics, {stack-monitor-app}, and Uptime.
[NOTE]
==============================================
@@ -55,16 +55,16 @@ If you create a rule in the {observability} app, its alerts are not visible in
| Detect complex conditions in *APM* data and trigger built-in actions when the conditions are met.
| {observability-guide}/create-alerts.html[Logs rules]
-| Detect complex conditions in the *Logs* app.
+| Detect complex conditions in the {logs-app}.
| {observability-guide}/create-alerts.html[Metrics rules]
-| Detect complex conditions in the *Metrics* app.
+| Detect complex conditions in the {metrics-app}.
-| <>
-| Provide {kib} Alerting rules out-of-the box to notify you of potential issues in the Elastic Stack.
+| <>
+| Provide {kib} alerting rules out-of-the box to notify you of potential issues in the {stack}.
| {observability-guide}/create-alerts.html[Uptime rules]
-| Detect complex conditions in the *Uptime* app.
+| Detect complex conditions in the {uptime-app}.
|===
@@ -87,5 +87,5 @@ they are not visible in *{stack-manage-app} > {rules-ui}*.
==============================================
include::rule-types/index-threshold.asciidoc[]
-include::rule-types/es-query.asciidoc[]
+include::rule-types/es-query.asciidoc[leveloffset=+1]
include::rule-types/geo-rule-types.asciidoc[]
diff --git a/docs/user/alerting/rule-types/es-query.asciidoc b/docs/user/alerting/rule-types/es-query.asciidoc
index 8556aa11d19db..715fabc6fdc38 100644
--- a/docs/user/alerting/rule-types/es-query.asciidoc
+++ b/docs/user/alerting/rule-types/es-query.asciidoc
@@ -1,6 +1,5 @@
[[rule-type-es-query]]
-[role="xpack"]
-=== {es} query
+== {es} query
The {es} query rule type runs a user-configured query, compares the number of
matches to a configured threshold, and schedules actions to run when the
@@ -8,14 +7,14 @@ threshold condition is met.
[float]
-==== Create the rule
+=== Create the rule
Fill in the <>, then select
*{es} query*.
[float]
-==== Define the conditions
+=== Define the conditions
Define properties to detect the condition.
@@ -38,11 +37,11 @@ Time window:: Defines how far back to search for documents, using the
value higher than the *check every* value in the
<>, to avoid gaps in
detection.
-Exclude the hits from previous run:: Turn on to avoid alert duplication by
+Exclude matches from previous run:: Turn on to avoid alert duplication by
excluding documents that have already been detected by the previous rule run.
[float]
-==== Add action variables
+=== Add action variables
<> to run when the rule condition
is met. The following variables are specific to the {es} query rule. You can
@@ -109,7 +108,7 @@ Labels:
--
[float]
-==== Test your query
+=== Test your query
Use the *Test query* feature to verify that your query DSL is valid.
@@ -125,11 +124,12 @@ image::user/alerting/images/rule-types-es-query-valid.png[Test {es} query return
image::user/alerting/images/rule-types-es-query-invalid.png[Test {es} query shows error when invalid]
[float]
-==== Handling multiple matches of the same document
+=== Handling multiple matches of the same document
-This rule type checks for duplication of document matches across multiple runs.
-If you configure the rule with a schedule interval smaller than the time window,
-and a document matches a query in multiple runs, it is alerted on only once.
+By default, *Exclude matches from previous run* is turned on and the rule checks
+for duplication of document matches across multiple runs. If you configure the
+rule with a schedule interval smaller than the time window and a document
+matches a query in multiple runs, it is alerted on only once.
The rule uses the timestamp of the matches to avoid alerting on the same match
multiple times. The timestamp of the latest match is used for evaluating the
diff --git a/docs/user/alerting/troubleshooting/alerting-common-issues.asciidoc b/docs/user/alerting/troubleshooting/alerting-common-issues.asciidoc
index 75a158e6d364f..a8ee7cbecab21 100644
--- a/docs/user/alerting/troubleshooting/alerting-common-issues.asciidoc
+++ b/docs/user/alerting/troubleshooting/alerting-common-issues.asciidoc
@@ -72,7 +72,7 @@ By default, only users with a `superuser` role can query the experimental[] {kib
*Solution*
-By default, rules have a `5m` timeout. Rules that run longer than this timeout are automatically cancelled to prevent them from consuming too much of {kib}'s resources. Alerts and actions that may have been scheduled before the rule timed out are discarded. When a rule times out, you will see this error in the {kib} logs:
+By default, rules have a `5m` timeout. Rules that run longer than this timeout are automatically canceled to prevent them from consuming too much of {kib}'s resources. Alerts and actions that may have been scheduled before the rule timed out are discarded. When a rule times out, you will see this error in the {kib} logs:
[source,sh]
--------------------------------------------------
@@ -243,7 +243,7 @@ Use the <> to retrieve additional information about r
[float]
[[rule-cannot-decrypt-api-key]]
-==== Rule cannot decrypt apiKey
+==== Rule cannot decrypt API key
*Problem*:
diff --git a/docs/user/alerting/troubleshooting/testing-connectors.asciidoc b/docs/user/alerting/troubleshooting/testing-connectors.asciidoc
index fd5a897dfd4c3..4207a6af23239 100644
--- a/docs/user/alerting/troubleshooting/testing-connectors.asciidoc
+++ b/docs/user/alerting/troubleshooting/testing-connectors.asciidoc
@@ -3,7 +3,7 @@
=== Test connectors
-By using Kibana Management UI you can test a newly created Connector by navigating to the Test tab of Connector Edit flyout or by clicking "Save & test" button on Create flyout:
+In *{stack-manage-app} > {rules-ui}*, you can test a newly created connector by navigating to the Test tab of Connector Edit flyout or by clicking "Save & test" button on Create flyout:
[role="screenshot"]
image::user/alerting/images/connector-save-and-test.png[Rule management page with the errors banner]
diff --git a/nav-kibana-dev.docnav.json b/nav-kibana-dev.docnav.json
index 40c4858d89f7d..b9fd0eef45c10 100644
--- a/nav-kibana-dev.docnav.json
+++ b/nav-kibana-dev.docnav.json
@@ -171,6 +171,9 @@
{
"label": "Contributors Newsletters",
"items": [
+ {
+ "id": "kibAugust2022ContributorNewsletter"
+ },
{
"id": "kibJuly2022ContributorNewsletter"
},
diff --git a/packages/analytics/client/src/analytics_client/types.ts b/packages/analytics/client/src/analytics_client/types.ts
index 2af29d88b5ceb..9a25f821b70a3 100644
--- a/packages/analytics/client/src/analytics_client/types.ts
+++ b/packages/analytics/client/src/analytics_client/types.ts
@@ -169,6 +169,8 @@ export interface IAnalyticsClient {
* Reports a telemetry event.
* @param eventType The event type registered via the `registerEventType` API.
* @param eventData The properties matching the schema declared in the `registerEventType` API.
+ *
+ * @track-adoption
*/
reportEvent: (
eventType: EventType,
@@ -198,8 +200,10 @@ export interface IAnalyticsClient {
*/
optIn: (optInConfig: OptInConfig) => void;
/**
- * Registers the context provider to enrich the any reported events.
+ * Registers the context provider to enrich any reported events.
* @param contextProviderOpts {@link ContextProviderOpts}
+ *
+ * @track-adoption
*/
registerContextProvider: (contextProviderOpts: ContextProviderOpts) => void;
/**
diff --git a/packages/core/chrome/core-chrome-browser-internal/src/chrome_service.tsx b/packages/core/chrome/core-chrome-browser-internal/src/chrome_service.tsx
index 5a4183eb88fc9..3c4b42cddfae7 100644
--- a/packages/core/chrome/core-chrome-browser-internal/src/chrome_service.tsx
+++ b/packages/core/chrome/core-chrome-browser-internal/src/chrome_service.tsx
@@ -223,6 +223,7 @@ export class ChromeService {
navControlsLeft$={navControls.getLeft$()}
navControlsCenter$={navControls.getCenter$()}
navControlsRight$={navControls.getRight$()}
+ navControlsExtension$={navControls.getExtension$()}
onIsLockedUpdate={setIsNavDrawerLocked}
isLocked$={getIsNavDrawerLocked$}
/>
diff --git a/packages/core/chrome/core-chrome-browser-internal/src/nav_controls/nav_controls_service.ts b/packages/core/chrome/core-chrome-browser-internal/src/nav_controls/nav_controls_service.ts
index b38cfb76cb3be..36f448b187e13 100644
--- a/packages/core/chrome/core-chrome-browser-internal/src/nav_controls/nav_controls_service.ts
+++ b/packages/core/chrome/core-chrome-browser-internal/src/nav_controls/nav_controls_service.ts
@@ -19,6 +19,7 @@ export class NavControlsService {
const navControlsLeft$ = new BehaviorSubject>(new Set());
const navControlsRight$ = new BehaviorSubject>(new Set());
const navControlsCenter$ = new BehaviorSubject>(new Set());
+ const navControlsExtension$ = new BehaviorSubject>(new Set());
return {
// In the future, registration should be moved to the setup phase. This
@@ -32,6 +33,9 @@ export class NavControlsService {
registerCenter: (navControl: ChromeNavControl) =>
navControlsCenter$.next(new Set([...navControlsCenter$.value.values(), navControl])),
+ registerExtension: (navControl: ChromeNavControl) =>
+ navControlsExtension$.next(new Set([...navControlsExtension$.value.values(), navControl])),
+
getLeft$: () =>
navControlsLeft$.pipe(
map((controls) => sortBy([...controls.values()], 'order')),
@@ -47,6 +51,11 @@ export class NavControlsService {
map((controls) => sortBy([...controls.values()], 'order')),
takeUntil(this.stop$)
),
+ getExtension$: () =>
+ navControlsExtension$.pipe(
+ map((controls) => sortBy([...controls.values()], 'order')),
+ takeUntil(this.stop$)
+ ),
};
}
diff --git a/packages/core/chrome/core-chrome-browser-internal/src/ui/header/__snapshots__/header.test.tsx.snap b/packages/core/chrome/core-chrome-browser-internal/src/ui/header/__snapshots__/header.test.tsx.snap
index d00e26bfcfe99..2a42112f30a81 100644
--- a/packages/core/chrome/core-chrome-browser-internal/src/ui/header/__snapshots__/header.test.tsx.snap
+++ b/packages/core/chrome/core-chrome-browser-internal/src/ui/header/__snapshots__/header.test.tsx.snap
@@ -65,6 +65,9 @@ exports[`Header renders 1`] = `
+
diff --git a/x-pack/plugins/aiops/public/components/spike_analysis_table/spike_analysis_table.tsx b/x-pack/plugins/aiops/public/components/spike_analysis_table/spike_analysis_table.tsx
index 6ae778e48e3e0..b35fbe971b011 100644
--- a/x-pack/plugins/aiops/public/components/spike_analysis_table/spike_analysis_table.tsx
+++ b/x-pack/plugins/aiops/public/components/spike_analysis_table/spike_analysis_table.tsx
@@ -18,22 +18,31 @@ import { sortBy } from 'lodash';
import { i18n } from '@kbn/i18n';
import { FormattedMessage } from '@kbn/i18n-react';
+import { escapeKuery } from '@kbn/es-query';
import type { ChangePoint } from '@kbn/ml-agg-utils';
-
import { useEuiTheme } from '../../hooks/use_eui_theme';
-
import { MiniHistogram } from '../mini_histogram';
+import { useAiOpsKibana } from '../../kibana_context';
+import { SEARCH_QUERY_LANGUAGE } from '../../application/utils/search_utils';
import { getFailedTransactionsCorrelationImpactLabel } from './get_failed_transactions_correlation_impact_label';
const NARROW_COLUMN_WIDTH = '120px';
+const ACTIONS_COLUMN_WIDTH = '60px';
const PAGINATION_SIZE_OPTIONS = [5, 10, 20, 50];
const DEFAULT_SORT_FIELD = 'pValue';
const DEFAULT_SORT_DIRECTION = 'asc';
+const viewInDiscoverMessage = i18n.translate(
+ 'xpack.aiops.spikeAnalysisTable.linksMenu.viewInDiscover',
+ {
+ defaultMessage: 'View in Discover',
+ }
+);
interface SpikeAnalysisTableProps {
changePoints: ChangePoint[];
+ dataViewId?: string;
loading: boolean;
onPinnedChangePoint?: (changePoint: ChangePoint | null) => void;
onSelectedChangePoint?: (changePoint: ChangePoint | null) => void;
@@ -42,6 +51,7 @@ interface SpikeAnalysisTableProps {
export const SpikeAnalysisTable: FC = ({
changePoints,
+ dataViewId,
loading,
onPinnedChangePoint,
onSelectedChangePoint,
@@ -54,6 +64,67 @@ export const SpikeAnalysisTable: FC = ({
const [sortField, setSortField] = useState(DEFAULT_SORT_FIELD);
const [sortDirection, setSortDirection] = useState<'asc' | 'desc'>(DEFAULT_SORT_DIRECTION);
+ const aiOpsKibana = useAiOpsKibana();
+ const {
+ services: { application, share, data },
+ } = aiOpsKibana;
+
+ const discoverLocator = useMemo(
+ () => share.url.locators.get('DISCOVER_APP_LOCATOR'),
+ [share.url.locators]
+ );
+
+ const discoverUrlError = useMemo(() => {
+ if (!application.capabilities.discover?.show) {
+ const discoverNotEnabled = i18n.translate(
+ 'xpack.aiops.spikeAnalysisTable.discoverNotEnabledErrorMessage',
+ {
+ defaultMessage: 'Discover is not enabled',
+ }
+ );
+
+ return discoverNotEnabled;
+ }
+ if (!discoverLocator) {
+ const discoverLocatorMissing = i18n.translate(
+ 'xpack.aiops.spikeAnalysisTable.discoverLocatorMissingErrorMessage',
+ {
+ defaultMessage: 'No locator for Discover detected',
+ }
+ );
+
+ return discoverLocatorMissing;
+ }
+ if (!dataViewId) {
+ const autoGeneratedDiscoverLinkError = i18n.translate(
+ 'xpack.aiops.spikeAnalysisTable.autoGeneratedDiscoverLinkErrorMessage',
+ {
+ defaultMessage: 'Unable to link to Discover; no data view exists for this index',
+ }
+ );
+
+ return autoGeneratedDiscoverLinkError;
+ }
+ }, [application.capabilities.discover?.show, dataViewId, discoverLocator]);
+
+ const generateDiscoverUrl = async (changePoint: ChangePoint) => {
+ if (discoverLocator !== undefined) {
+ const url = await discoverLocator.getRedirectUrl({
+ indexPatternId: dataViewId,
+ timeRange: data.query.timefilter.timefilter.getTime(),
+ filters: data.query.filterManager.getFilters(),
+ query: {
+ language: SEARCH_QUERY_LANGUAGE.KUERY,
+ query: `${escapeKuery(changePoint.fieldName)}:${escapeKuery(
+ String(changePoint.fieldValue)
+ )}`,
+ },
+ });
+
+ return url;
+ }
+ };
+
const columns: Array> = [
{
'data-test-subj': 'aiopsSpikeAnalysisTableColumnFieldName',
@@ -163,6 +234,31 @@ export const SpikeAnalysisTable: FC = ({
},
sortable: true,
},
+ {
+ 'data-test-subj': 'aiOpsSpikeAnalysisTableColumnAction',
+ name: i18n.translate('xpack.aiops.spikeAnalysisTable.actionsColumnName', {
+ defaultMessage: 'Actions',
+ }),
+ actions: [
+ {
+ name: () => (
+
+
+
+ ),
+ description: viewInDiscoverMessage,
+ type: 'button',
+ onClick: async (changePoint) => {
+ const openInDiscoverUrl = await generateDiscoverUrl(changePoint);
+ if (typeof openInDiscoverUrl === 'string') {
+ await application.navigateToUrl(openInDiscoverUrl);
+ }
+ },
+ enabled: () => discoverUrlError === undefined,
+ },
+ ],
+ width: ACTIONS_COLUMN_WIDTH,
+ },
];
const onChange = useCallback((tableSettings) => {
diff --git a/x-pack/plugins/aiops/public/plugin.ts b/x-pack/plugins/aiops/public/plugin.ts
index dd903b08e2eb4..c6126ec2db7a9 100755
--- a/x-pack/plugins/aiops/public/plugin.ts
+++ b/x-pack/plugins/aiops/public/plugin.ts
@@ -10,6 +10,7 @@ import type { DataPublicPluginStart } from '@kbn/data-plugin/public';
import type { UnifiedSearchPublicPluginStart } from '@kbn/unified-search-plugin/public';
import { ChartsPluginStart } from '@kbn/charts-plugin/public';
import { FieldFormatsStart } from '@kbn/field-formats-plugin/public';
+import type { SharePluginStart } from '@kbn/share-plugin/public';
import { AiopsPluginSetup, AiopsPluginStart } from './types';
import { setStartServices } from './kibana_services';
@@ -19,6 +20,7 @@ export interface AiOpsStartDependencies {
charts: ChartsPluginStart;
fieldFormats: FieldFormatsStart;
unifiedSearch: UnifiedSearchPublicPluginStart;
+ share: SharePluginStart;
}
export class AiopsPlugin implements Plugin {
diff --git a/x-pack/plugins/enterprise_search/common/types/analytics.ts b/x-pack/plugins/enterprise_search/common/types/analytics.ts
index e75617645a139..4f6ed8d3a147d 100644
--- a/x-pack/plugins/enterprise_search/common/types/analytics.ts
+++ b/x-pack/plugins/enterprise_search/common/types/analytics.ts
@@ -6,9 +6,9 @@
*/
export interface AnalyticsCollection {
+ event_retention_day_length: number;
id: string;
name: string;
- event_retention_day_length: number;
}
export type AnalyticsCollectionDocument = Omit;
diff --git a/x-pack/plugins/enterprise_search/common/types/connectors.ts b/x-pack/plugins/enterprise_search/common/types/connectors.ts
index 3c986d4ac1143..26b7ef917f435 100644
--- a/x-pack/plugins/enterprise_search/common/types/connectors.ts
+++ b/x-pack/plugins/enterprise_search/common/types/connectors.ts
@@ -39,7 +39,7 @@ export interface Connector {
language: string | null;
last_seen: string | null;
last_sync_error: string | null;
- last_sync_status: string | null;
+ last_sync_status: SyncStatus | null;
last_synced: string | null;
name: string;
scheduling: {
@@ -52,3 +52,16 @@ export interface Connector {
}
export type ConnectorDocument = Omit;
+
+export interface ConnectorSyncJob {
+ completed_at: string | null;
+ connector?: ConnectorDocument;
+ connector_id: string;
+ created_at: string;
+ deleted_document_count: number;
+ error: string | null;
+ index_name: string;
+ indexed_document_count: number;
+ status: SyncStatus;
+ worker_hostname: string;
+}
diff --git a/x-pack/plugins/enterprise_search/common/types/error_codes.ts b/x-pack/plugins/enterprise_search/common/types/error_codes.ts
index 46aa735f97d2a..e0e4070e167e1 100644
--- a/x-pack/plugins/enterprise_search/common/types/error_codes.ts
+++ b/x-pack/plugins/enterprise_search/common/types/error_codes.ts
@@ -8,6 +8,7 @@
export enum ErrorCode {
ANALYTICS_COLLECTION_ALREADY_EXISTS = 'analytics_collection_already_exists',
ANALYTICS_COLLECTION_NOT_FOUND = 'analytics_collection_not_found',
+ ANALYTICS_COLLECTION_NAME_INVALID = 'analytics_collection_name_invalid',
CONNECTOR_DOCUMENT_ALREADY_EXISTS = 'connector_document_already_exists',
CRAWLER_ALREADY_EXISTS = 'crawler_already_exists',
INDEX_ALREADY_EXISTS = 'index_already_exists',
diff --git a/x-pack/plugins/enterprise_search/common/types/pagination.ts b/x-pack/plugins/enterprise_search/common/types/pagination.ts
new file mode 100644
index 0000000000000..04f0fa6a46bc7
--- /dev/null
+++ b/x-pack/plugins/enterprise_search/common/types/pagination.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.
+ */
+
+export interface Paginate {
+ data: T[];
+ has_more_hits_than_total: boolean;
+ pageIndex: number;
+ pageSize: number;
+ size: number;
+ total: number;
+}
diff --git a/x-pack/plugins/enterprise_search/common/utils/is_alphanumeric_underscore.test.ts b/x-pack/plugins/enterprise_search/common/utils/is_alphanumeric_underscore.test.ts
new file mode 100644
index 0000000000000..f44f2f9eb7eb9
--- /dev/null
+++ b/x-pack/plugins/enterprise_search/common/utils/is_alphanumeric_underscore.test.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 { isAlphaNumericOrUnderscore } from './is_alphanumeric_underscore';
+
+describe('isAlphanumericUnderscore', () => {
+ it('should return true for valid inputs', () => {
+ expect(isAlphaNumericOrUnderscore('test')).toBe(true);
+ expect(isAlphaNumericOrUnderscore('test_one')).toBe(true);
+ });
+
+ it('should return false for invalid inputs', () => {
+ expect(isAlphaNumericOrUnderscore('')).toBe(false);
+ expect(isAlphaNumericOrUnderscore('test!')).toBe(false);
+ expect(isAlphaNumericOrUnderscore('testç')).toBe(false);
+ expect(isAlphaNumericOrUnderscore('test_one-s')).toBe(false);
+ });
+});
diff --git a/x-pack/plugins/enterprise_search/common/utils/is_alphanumeric_underscore.ts b/x-pack/plugins/enterprise_search/common/utils/is_alphanumeric_underscore.ts
new file mode 100644
index 0000000000000..446bb7c805e13
--- /dev/null
+++ b/x-pack/plugins/enterprise_search/common/utils/is_alphanumeric_underscore.ts
@@ -0,0 +1,10 @@
+/*
+ * 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 isAlphaNumericOrUnderscore = (input: string): boolean => {
+ return input.length > 0 && /^(\w)+$/.test(input);
+};
diff --git a/x-pack/plugins/enterprise_search/public/applications/analytics/api/add_analytics_collection/add_analytics_collection_api_logic.test.ts b/x-pack/plugins/enterprise_search/public/applications/analytics/api/add_analytics_collection/add_analytics_collection_api_logic.test.ts
new file mode 100644
index 0000000000000..2b1fb081f51c5
--- /dev/null
+++ b/x-pack/plugins/enterprise_search/public/applications/analytics/api/add_analytics_collection/add_analytics_collection_api_logic.test.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 { mockHttpValues } from '../../../__mocks__/kea_logic';
+
+import { nextTick } from '@kbn/test-jest-helpers';
+
+import { createAnalyticsCollection } from './add_analytics_collection_api_logic';
+
+describe('AddAnalyticsCollectionsApiLogic', () => {
+ const { http } = mockHttpValues;
+ beforeEach(() => {
+ jest.clearAllMocks();
+ });
+
+ describe('AddAnalyticsCollectionsApiLogic', () => {
+ it('Calls the analytics collections create api', async () => {
+ const promise = Promise.resolve({ name: 'test' });
+ http.post.mockReturnValue(promise);
+ const result = createAnalyticsCollection({ name: 'test' });
+ await nextTick();
+ expect(http.post).toHaveBeenCalledWith('/internal/enterprise_search/analytics/collections', {
+ body: JSON.stringify({ name: 'test' }),
+ });
+ await expect(result).resolves.toEqual({ name: 'test' });
+ });
+ });
+});
diff --git a/x-pack/plugins/enterprise_search/public/applications/analytics/api/add_analytics_collection/add_analytics_collection_api_logic.ts b/x-pack/plugins/enterprise_search/public/applications/analytics/api/add_analytics_collection/add_analytics_collection_api_logic.ts
new file mode 100644
index 0000000000000..6b5e17b188d0f
--- /dev/null
+++ b/x-pack/plugins/enterprise_search/public/applications/analytics/api/add_analytics_collection/add_analytics_collection_api_logic.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 { AnalyticsCollection } from '../../../../../common/types/analytics';
+
+import { createApiLogic } from '../../../shared/api_logic/create_api_logic';
+import { HttpLogic } from '../../../shared/http';
+
+export interface AddAnalyticsCollectionApiLogicArgs {
+ name: string;
+}
+
+export type AddAnalyticsCollectionApiLogicResponse = AnalyticsCollection;
+
+export const createAnalyticsCollection = async ({
+ name,
+}: AddAnalyticsCollectionApiLogicArgs): Promise => {
+ const { http } = HttpLogic.values;
+ const route = '/internal/enterprise_search/analytics/collections';
+ const response = await http.post(route, {
+ body: JSON.stringify({ name }),
+ });
+
+ return response;
+};
+
+export const AddAnalyticsCollectionsAPILogic = createApiLogic(
+ ['analytics', 'add_analytics_collections_api_logic'],
+ createAnalyticsCollection
+);
diff --git a/x-pack/plugins/enterprise_search/public/applications/analytics/api/index/fetch_analytics_collections_api_logic.ts b/x-pack/plugins/enterprise_search/public/applications/analytics/api/index/fetch_analytics_collections_api_logic.ts
index 19956e6806288..399038a776c10 100644
--- a/x-pack/plugins/enterprise_search/public/applications/analytics/api/index/fetch_analytics_collections_api_logic.ts
+++ b/x-pack/plugins/enterprise_search/public/applications/analytics/api/index/fetch_analytics_collections_api_logic.ts
@@ -10,10 +10,12 @@ import { AnalyticsCollection } from '../../../../../common/types/analytics';
import { createApiLogic } from '../../../shared/api_logic/create_api_logic';
import { HttpLogic } from '../../../shared/http';
+export type FetchAnalyticsCollectionsApiLogicResponse = AnalyticsCollection[];
+
export const fetchAnalyticsCollections = async () => {
const { http } = HttpLogic.values;
const route = '/internal/enterprise_search/analytics/collections';
- const response = await http.get(route);
+ const response = await http.get(route);
return response;
};
diff --git a/x-pack/plugins/enterprise_search/public/applications/analytics/components/add_analytics_collections/add_analytics_collection.test.tsx b/x-pack/plugins/enterprise_search/public/applications/analytics/components/add_analytics_collections/add_analytics_collection.test.tsx
new file mode 100644
index 0000000000000..f635b0699e0bb
--- /dev/null
+++ b/x-pack/plugins/enterprise_search/public/applications/analytics/components/add_analytics_collections/add_analytics_collection.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; you may not use this file except in compliance with the Elastic License
+ * 2.0.
+ */
+
+import '../../../__mocks__/shallow_useeffect.mock';
+
+import React from 'react';
+
+import { shallow } from 'enzyme';
+
+import { AddAnalyticsCollection } from './add_analytics_collection';
+import { AddAnalyticsCollectionForm } from './add_analytics_collection_form';
+
+describe('AddAnalyticsCollection', () => {
+ beforeEach(() => {
+ jest.clearAllMocks();
+ });
+
+ it('renders', () => {
+ const wrapper = shallow();
+ expect(wrapper.find(AddAnalyticsCollectionForm)).toHaveLength(1);
+ });
+});
diff --git a/x-pack/plugins/enterprise_search/public/applications/analytics/components/add_analytics_collections/add_analytics_collection.tsx b/x-pack/plugins/enterprise_search/public/applications/analytics/components/add_analytics_collections/add_analytics_collection.tsx
new file mode 100644
index 0000000000000..0a6a7891a782a
--- /dev/null
+++ b/x-pack/plugins/enterprise_search/public/applications/analytics/components/add_analytics_collections/add_analytics_collection.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; you may not use this file except in compliance with the Elastic License
+ * 2.0.
+ */
+
+import React from 'react';
+
+import { i18n } from '@kbn/i18n';
+
+import { EnterpriseSearchAnalyticsPageTemplate } from '../layout/page_template';
+
+import { AddAnalyticsCollectionForm } from './add_analytics_collection_form';
+
+export const collectionsCreateBreadcrumbs = [
+ i18n.translate('xpack.enterpriseSearch.analytics.collectionsCreate.breadcrumb', {
+ defaultMessage: 'Create collection',
+ }),
+];
+
+export const AddAnalyticsCollection: React.FC = () => {
+ return (
+
+
+
+ );
+};
diff --git a/x-pack/plugins/enterprise_search/public/applications/analytics/components/add_analytics_collections/add_analytics_collection_form.test.tsx b/x-pack/plugins/enterprise_search/public/applications/analytics/components/add_analytics_collections/add_analytics_collection_form.test.tsx
new file mode 100644
index 0000000000000..3bf3cf0d4f721
--- /dev/null
+++ b/x-pack/plugins/enterprise_search/public/applications/analytics/components/add_analytics_collections/add_analytics_collection_form.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 '../../../__mocks__/shallow_useeffect.mock';
+
+import { setMockValues, setMockActions, mockKibanaValues } from '../../../__mocks__/kea_logic';
+
+import React from 'react';
+
+import { shallow } from 'enzyme';
+
+import { EuiButtonEmpty, EuiFieldText, EuiForm } from '@elastic/eui';
+
+import { AddAnalyticsCollectionForm } from './add_analytics_collection_form';
+
+const mockValues = {
+ canSubmit: true,
+ hasInputError: false,
+ inputError: false,
+ isLoading: false,
+ name: 'test',
+};
+
+const mockActions = {
+ createAnalyticsCollection: jest.fn(),
+ setNameValue: jest.fn(),
+};
+
+describe('AddAnalyticsCollectionForm', () => {
+ const { navigateToUrl } = mockKibanaValues;
+
+ beforeEach(() => {
+ jest.clearAllMocks();
+ });
+
+ it('renders', () => {
+ setMockValues(mockValues);
+ setMockActions(mockActions);
+
+ const wrapper = shallow();
+ expect(wrapper.find(EuiForm)).toHaveLength(1);
+ });
+
+ it('navigates back to root when cancel is clicked', () => {
+ setMockValues(mockValues);
+ setMockActions(mockActions);
+
+ const wrapper = shallow();
+
+ wrapper.find(EuiButtonEmpty).simulate('click');
+ expect(navigateToUrl).toHaveBeenCalledWith('/');
+ });
+
+ it('submit form will call create analytics collection action', () => {
+ setMockValues(mockValues);
+ setMockActions(mockActions);
+
+ const wrapper = shallow();
+
+ wrapper.find(EuiForm).simulate('submit', { preventDefault: jest.fn() });
+ expect(mockActions.createAnalyticsCollection).toHaveBeenCalled();
+ });
+
+ it('cannot call createAnalyticsCollection when form has errors', () => {
+ setMockValues({
+ ...mockValues,
+ canSubmit: false,
+ hasInputError: true,
+ });
+ setMockActions(mockActions);
+
+ const wrapper = shallow();
+
+ wrapper.find(EuiForm).simulate('submit', { preventDefault: jest.fn() });
+ expect(mockActions.createAnalyticsCollection).not.toHaveBeenCalled();
+ });
+
+ it('should call setNameValue action when input is updated', () => {
+ setMockValues(mockValues);
+ setMockActions(mockActions);
+
+ const wrapper = shallow();
+
+ wrapper.find(EuiFieldText).simulate('change', { target: { value: 'test' } });
+ expect(mockActions.setNameValue).toHaveBeenCalledWith('test');
+ });
+});
diff --git a/x-pack/plugins/enterprise_search/public/applications/analytics/components/add_analytics_collections/add_analytics_collection_form.tsx b/x-pack/plugins/enterprise_search/public/applications/analytics/components/add_analytics_collections/add_analytics_collection_form.tsx
new file mode 100644
index 0000000000000..0088a8462d281
--- /dev/null
+++ b/x-pack/plugins/enterprise_search/public/applications/analytics/components/add_analytics_collections/add_analytics_collection_form.tsx
@@ -0,0 +1,128 @@
+/*
+ * 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 {
+ EuiFlexGroup,
+ EuiFlexItem,
+ EuiPanel,
+ EuiTitle,
+ EuiSpacer,
+ EuiText,
+ EuiButtonEmpty,
+ EuiFormRow,
+ EuiFieldText,
+ EuiForm,
+ EuiButton,
+} from '@elastic/eui';
+
+import { i18n } from '@kbn/i18n';
+
+import { KibanaLogic } from '../../../shared/kibana';
+import { ROOT_PATH } from '../../routes';
+
+import { AddAnalyticsCollectionLogic } from './add_analytics_collection_logic';
+
+export const AddAnalyticsCollectionForm = () => {
+ const { createAnalyticsCollection, setNameValue } = useActions(AddAnalyticsCollectionLogic);
+ const { name, inputError, hasInputError, isLoading, canSubmit } = useValues(
+ AddAnalyticsCollectionLogic
+ );
+ const { navigateToUrl } = useValues(KibanaLogic);
+
+ return (
+
+
+
+
+
+ {i18n.translate('xpack.enterpriseSearch.analytics.collectionsCreate.form.title', {
+ defaultMessage: 'Create an analytics collection',
+ })}
+
+
+
+
+
+ {i18n.translate('xpack.enterpriseSearch.analytics.collectionsCreate.form.subtitle', {
+ defaultMessage:
+ 'An analytics collection provides a place to store the analytics events for any given search application you are building. Give it a memorable name below.',
+ })}
+
+
+
+ {
+ e.preventDefault();
+ if (canSubmit) {
+ createAnalyticsCollection();
+ }
+ }}
+ >
+
+ {
+ setNameValue(e.target.value);
+ }}
+ />
+
+
+
+
+ {
+ navigateToUrl(ROOT_PATH);
+ }}
+ >
+ {i18n.translate(
+ 'xpack.enterpriseSearch.analytics.collectionsCreate.form.cancelButton',
+ {
+ defaultMessage: 'Cancel',
+ }
+ )}
+
+
+
+
+ {i18n.translate(
+ 'xpack.enterpriseSearch.analytics.collectionsCreate.form.continueButton',
+ {
+ defaultMessage: 'Continue',
+ }
+ )}
+
+
+
+
+
+
+
+ );
+};
diff --git a/x-pack/plugins/enterprise_search/public/applications/analytics/components/add_analytics_collections/add_analytics_collection_logic.test.ts b/x-pack/plugins/enterprise_search/public/applications/analytics/components/add_analytics_collections/add_analytics_collection_logic.test.ts
new file mode 100644
index 0000000000000..b9355574e0806
--- /dev/null
+++ b/x-pack/plugins/enterprise_search/public/applications/analytics/components/add_analytics_collections/add_analytics_collection_logic.test.ts
@@ -0,0 +1,171 @@
+/*
+ * 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 {
+ LogicMounter,
+ mockFlashMessageHelpers,
+ mockHttpValues,
+ mockKibanaValues,
+} from '../../../__mocks__/kea_logic';
+
+import { nextTick } from '@kbn/test-jest-helpers';
+
+import { AnalyticsCollection } from '../../../../../common/types/analytics';
+import { HttpError, Status } from '../../../../../common/types/api';
+
+import { AddAnalyticsCollectionLogic } from './add_analytics_collection_logic';
+
+describe('addAnalyticsCollectionLogic', () => {
+ const { mount } = new LogicMounter(AddAnalyticsCollectionLogic);
+ const { flashSuccessToast, flashAPIErrors } = mockFlashMessageHelpers;
+ const { http } = mockHttpValues;
+
+ beforeEach(() => {
+ jest.clearAllMocks();
+ mount();
+ });
+
+ it('has expected default values', () => {
+ expect(AddAnalyticsCollectionLogic.values).toEqual({
+ canSubmit: false,
+ hasInputError: false,
+ inputError: null,
+ isLoading: false,
+ name: '',
+ status: Status.IDLE,
+ });
+ });
+
+ describe('actions', () => {
+ describe('setInputError', () => {
+ it('should set error state', () => {
+ AddAnalyticsCollectionLogic.actions.setInputError('error');
+ expect(AddAnalyticsCollectionLogic.values).toEqual({
+ canSubmit: false,
+ hasInputError: true,
+ inputError: 'error',
+ isLoading: false,
+ name: '',
+ status: Status.IDLE,
+ });
+ });
+
+ it('should reset error state', () => {
+ AddAnalyticsCollectionLogic.actions.setInputError(null);
+ expect(AddAnalyticsCollectionLogic.values).toEqual({
+ canSubmit: false,
+ hasInputError: false,
+ inputError: null,
+ isLoading: false,
+ name: '',
+ status: Status.IDLE,
+ });
+ });
+ });
+
+ describe('setNameValue', () => {
+ it('should error when name is invalid', () => {
+ AddAnalyticsCollectionLogic.actions.setNameValue('!invalid');
+ expect(AddAnalyticsCollectionLogic.values).toEqual({
+ canSubmit: false,
+ hasInputError: true,
+ inputError: 'Name must only contain alphanumeric characters and underscores',
+ isLoading: false,
+ name: '!invalid',
+ status: Status.IDLE,
+ });
+ });
+
+ it('should not show error when name is valid', () => {
+ AddAnalyticsCollectionLogic.actions.setNameValue('valid');
+ expect(AddAnalyticsCollectionLogic.values).toEqual({
+ canSubmit: true,
+ hasInputError: false,
+ inputError: null,
+ isLoading: false,
+ name: 'valid',
+ status: Status.IDLE,
+ });
+ });
+ });
+ });
+
+ describe('listeners', () => {
+ describe('onApiSuccess', () => {
+ it('should flash a success toast and navigate to collection view', async () => {
+ jest.useFakeTimers();
+
+ const { navigateToUrl } = mockKibanaValues;
+
+ AddAnalyticsCollectionLogic.actions.apiSuccess({
+ event_retention_day_length: 180,
+ id: 'bla',
+ name: 'test',
+ } as AnalyticsCollection);
+
+ expect(flashSuccessToast).toHaveBeenCalled();
+ jest.advanceTimersByTime(1000);
+ await nextTick();
+ expect(navigateToUrl).toHaveBeenCalledWith('/collections/test');
+ jest.useRealTimers();
+ });
+ });
+
+ describe('onApiError', () => {
+ it('should flash an error toast', () => {
+ const httpError: HttpError = {
+ body: {
+ error: 'Bad Request',
+ statusCode: 400,
+ },
+ fetchOptions: {},
+ request: {},
+ } as HttpError;
+ AddAnalyticsCollectionLogic.actions.apiError(httpError);
+
+ expect(flashAPIErrors).toHaveBeenCalledWith(httpError);
+ });
+ });
+
+ describe('createAnalyticsCollection', () => {
+ it('should call make request', () => {
+ mount({
+ name: 'test',
+ });
+ AddAnalyticsCollectionLogic.actions.makeRequest = jest.fn();
+ AddAnalyticsCollectionLogic.actions.createAnalyticsCollection();
+ expect(AddAnalyticsCollectionLogic.actions.makeRequest).toHaveBeenCalledWith({
+ name: 'test',
+ });
+ });
+ });
+ });
+
+ describe('selectors', () => {
+ describe('loading & status', () => {
+ it('updates when makeRequest triggered', () => {
+ const promise = Promise.resolve({ name: 'result' });
+ http.post.mockReturnValue(promise);
+ AddAnalyticsCollectionLogic.actions.makeRequest({ name: 'test' });
+
+ expect(AddAnalyticsCollectionLogic.values.isLoading).toBe(true);
+ expect(AddAnalyticsCollectionLogic.values.status).toBe(Status.LOADING);
+ });
+
+ it('updates when apiSuccess listener triggered', () => {
+ AddAnalyticsCollectionLogic.actions.apiSuccess({
+ event_retention_day_length: 180,
+ id: 'bla',
+ name: 'test',
+ });
+
+ expect(AddAnalyticsCollectionLogic.values.isLoading).toBe(true);
+ expect(AddAnalyticsCollectionLogic.values.status).toBe(Status.SUCCESS);
+ });
+ });
+ });
+});
diff --git a/x-pack/plugins/enterprise_search/public/applications/analytics/components/add_analytics_collections/add_analytics_collection_logic.ts b/x-pack/plugins/enterprise_search/public/applications/analytics/components/add_analytics_collections/add_analytics_collection_logic.ts
new file mode 100644
index 0000000000000..a1035168d8e87
--- /dev/null
+++ b/x-pack/plugins/enterprise_search/public/applications/analytics/components/add_analytics_collections/add_analytics_collection_logic.ts
@@ -0,0 +1,128 @@
+/*
+ * 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 { kea, MakeLogicType } from 'kea';
+
+import { i18n } from '@kbn/i18n';
+
+import { Status } from '../../../../../common/types/api';
+
+import { isAlphaNumericOrUnderscore } from '../../../../../common/utils/is_alphanumeric_underscore';
+import { Actions } from '../../../shared/api_logic/create_api_logic';
+import { generateEncodedPath } from '../../../shared/encode_path_params';
+import { flashAPIErrors, flashSuccessToast } from '../../../shared/flash_messages';
+import { KibanaLogic } from '../../../shared/kibana';
+import {
+ AddAnalyticsCollectionsAPILogic,
+ AddAnalyticsCollectionApiLogicArgs,
+ AddAnalyticsCollectionApiLogicResponse,
+} from '../../api/add_analytics_collection/add_analytics_collection_api_logic';
+import { COLLECTION_VIEW_PATH } from '../../routes';
+
+export interface AddAnalyticsCollectionsActions {
+ apiError: Actions<
+ AddAnalyticsCollectionApiLogicArgs,
+ AddAnalyticsCollectionApiLogicResponse
+ >['apiError'];
+ apiSuccess: Actions<
+ AddAnalyticsCollectionApiLogicArgs,
+ AddAnalyticsCollectionApiLogicResponse
+ >['apiSuccess'];
+ createAnalyticsCollection(): void;
+ makeRequest: Actions<
+ AddAnalyticsCollectionApiLogicArgs,
+ AddAnalyticsCollectionApiLogicResponse
+ >['makeRequest'];
+ setInputError(error: string | null): { inputError: string | null };
+ setNameValue(name: string): { name: string };
+}
+
+interface AddAnalyticsCollectionValues {
+ canSubmit: boolean;
+ hasInputError: boolean;
+ inputError: string | null;
+ isLoading: boolean;
+ name: string;
+ status: Status;
+}
+
+export const AddAnalyticsCollectionLogic = kea<
+ MakeLogicType
+>({
+ actions: {
+ createAnalyticsCollection: () => {},
+ setInputError: (inputError: string | boolean) => ({ inputError }),
+ setNameValue: (name: string) => ({ name }),
+ },
+ connect: {
+ actions: [AddAnalyticsCollectionsAPILogic, ['apiError', 'apiSuccess', 'makeRequest']],
+ values: [AddAnalyticsCollectionsAPILogic, ['status']],
+ },
+ listeners: ({ values, actions }) => ({
+ apiError: (error) => flashAPIErrors(error),
+ apiSuccess: async ({ name }, breakpoint) => {
+ // Wait for propagation of the new collection
+ flashSuccessToast(
+ i18n.translate('xpack.enterpriseSearch.analytics.collectionsCreate.action.successMessage', {
+ defaultMessage: "Successfully added collection '{name}'",
+ values: {
+ name,
+ },
+ })
+ );
+ await breakpoint(1000);
+ KibanaLogic.values.navigateToUrl(
+ generateEncodedPath(COLLECTION_VIEW_PATH, {
+ name,
+ })
+ );
+ },
+ createAnalyticsCollection: () => {
+ const { name } = values;
+ actions.makeRequest({ name });
+ },
+ setNameValue: ({ name }) => {
+ if (!isAlphaNumericOrUnderscore(name)) {
+ const message = i18n.translate(
+ 'xpack.enterpriseSearch.analytics.collectionsCreate.action.invalidCollectionName',
+ {
+ defaultMessage: 'Name must only contain alphanumeric characters and underscores',
+ }
+ );
+ return actions.setInputError(message);
+ }
+ return actions.setInputError(null);
+ },
+ }),
+ path: ['enterprise_search', 'analytics', 'add_analytics_collection'],
+ reducers: {
+ inputError: [
+ null,
+ {
+ setInputError: (_, { inputError }) => inputError,
+ },
+ ],
+ name: [
+ '',
+ {
+ setNameValue: (_, { name }) => name,
+ },
+ ],
+ },
+ selectors: ({ selectors }) => ({
+ canSubmit: [
+ () => [selectors.hasInputError, selectors.isLoading, selectors.name],
+ (hasInputError, isLoading, name) => !hasInputError && !isLoading && name.length > 0,
+ ],
+ hasInputError: [() => [selectors.inputError], (inputError) => inputError !== null],
+ isLoading: [
+ () => [selectors.status],
+ // includes success to include the redirect wait time
+ (status: Status) => [Status.LOADING, Status.SUCCESS].includes(status),
+ ],
+ }),
+});
diff --git a/x-pack/plugins/enterprise_search/public/applications/analytics/components/analytics_overview/analytics_collections_logic.test.ts b/x-pack/plugins/enterprise_search/public/applications/analytics/components/analytics_overview/analytics_collections_logic.test.ts
index 26bf8e8a48265..cec1141ff0abc 100644
--- a/x-pack/plugins/enterprise_search/public/applications/analytics/components/analytics_overview/analytics_collections_logic.test.ts
+++ b/x-pack/plugins/enterprise_search/public/applications/analytics/components/analytics_overview/analytics_collections_logic.test.ts
@@ -7,8 +7,6 @@
import { LogicMounter, mockFlashMessageHelpers } from '../../../__mocks__/kea_logic';
-import { nextTick } from '@kbn/test-jest-helpers';
-
import { HttpError, Status } from '../../../../../common/types/api';
import { AnalyticsCollectionsLogic } from './analytics_collections_logic';
@@ -79,11 +77,8 @@ describe('analyticsCollectionsLogic', () => {
});
it('calls makeRequest on fetchAnalyticsCollections', async () => {
- jest.useFakeTimers();
AnalyticsCollectionsLogic.actions.makeRequest = jest.fn();
AnalyticsCollectionsLogic.actions.fetchAnalyticsCollections();
- jest.advanceTimersByTime(150);
- await nextTick();
expect(AnalyticsCollectionsLogic.actions.makeRequest).toHaveBeenCalledWith({});
});
});
diff --git a/x-pack/plugins/enterprise_search/public/applications/analytics/components/analytics_overview/analytics_collections_logic.ts b/x-pack/plugins/enterprise_search/public/applications/analytics/components/analytics_overview/analytics_collections_logic.ts
index e216506fdf978..5736680893b2b 100644
--- a/x-pack/plugins/enterprise_search/public/applications/analytics/components/analytics_overview/analytics_collections_logic.ts
+++ b/x-pack/plugins/enterprise_search/public/applications/analytics/components/analytics_overview/analytics_collections_logic.ts
@@ -8,22 +8,26 @@
import { kea, MakeLogicType } from 'kea';
import { AnalyticsCollection } from '../../../../../common/types/analytics';
-import { HttpError, Status } from '../../../../../common/types/api';
+import { Status } from '../../../../../common/types/api';
+import { Actions } from '../../../shared/api_logic/create_api_logic';
import { flashAPIErrors, clearFlashMessages } from '../../../shared/flash_messages';
-import { FetchAnalyticsCollectionsAPILogic } from '../../api/index/fetch_analytics_collections_api_logic';
+import {
+ FetchAnalyticsCollectionsAPILogic,
+ FetchAnalyticsCollectionsApiLogicResponse,
+} from '../../api/index/fetch_analytics_collections_api_logic';
export interface AnalyticsCollectionsActions {
- apiError(error: HttpError): HttpError;
- apiSuccess(collections: AnalyticsCollection[]): AnalyticsCollection[];
+ apiError: Actions<{}, FetchAnalyticsCollectionsApiLogicResponse>['apiError'];
+ apiSuccess: Actions<{}, FetchAnalyticsCollectionsApiLogicResponse>['apiSuccess'];
fetchAnalyticsCollections(): void;
- makeRequest: typeof FetchAnalyticsCollectionsAPILogic.actions.makeRequest;
+ makeRequest: Actions<{}, FetchAnalyticsCollectionsApiLogicResponse>['makeRequest'];
}
export interface AnalyticsCollectionsValues {
analyticsCollections: AnalyticsCollection[];
data: typeof FetchAnalyticsCollectionsAPILogic.values.data;
hasNoAnalyticsCollections: boolean;
isLoading: boolean;
- status: typeof FetchAnalyticsCollectionsAPILogic.values.status;
+ status: Status;
}
export const AnalyticsCollectionsLogic = kea<
diff --git a/x-pack/plugins/enterprise_search/public/applications/analytics/components/analytics_overview/analytics_overview.tsx b/x-pack/plugins/enterprise_search/public/applications/analytics/components/analytics_overview/analytics_overview.tsx
index 551fdc04656d0..0fd3518240fbb 100644
--- a/x-pack/plugins/enterprise_search/public/applications/analytics/components/analytics_overview/analytics_overview.tsx
+++ b/x-pack/plugins/enterprise_search/public/applications/analytics/components/analytics_overview/analytics_overview.tsx
@@ -20,12 +20,6 @@ import { EnterpriseSearchAnalyticsPageTemplate } from '../layout/page_template';
import { AnalyticsCollectionTable } from './analytics_collection_table';
import { AnalyticsCollectionsLogic } from './analytics_collections_logic';
-export const baseBreadcrumbs = [
- i18n.translate('xpack.enterpriseSearch.analytics.collections.breadcrumb', {
- defaultMessage: 'Analytics collections',
- }),
-];
-
export const AnalyticsOverview: React.FC = () => {
const { fetchAnalyticsCollections } = useActions(AnalyticsCollectionsLogic);
const { analyticsCollections, isLoading, hasNoAnalyticsCollections } =
@@ -37,7 +31,7 @@ export const AnalyticsOverview: React.FC = () => {
return (
= (props) => {
const { enterpriseSearchVersion, kibanaVersion } = props;
@@ -32,6 +34,9 @@ export const Analytics: React.FC = (props) => {
)}
+
+
+
);
};
diff --git a/x-pack/plugins/enterprise_search/public/applications/enterprise_search_content/api/connector/fetch_sync_jobs_api_logic.test.ts b/x-pack/plugins/enterprise_search/public/applications/enterprise_search_content/api/connector/fetch_sync_jobs_api_logic.test.ts
new file mode 100644
index 0000000000000..eadad25b8342a
--- /dev/null
+++ b/x-pack/plugins/enterprise_search/public/applications/enterprise_search_content/api/connector/fetch_sync_jobs_api_logic.test.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 { mockHttpValues } from '../../../__mocks__/kea_logic';
+
+import { nextTick } from '@kbn/test-jest-helpers';
+
+import { fetchSyncJobs } from './fetch_sync_jobs_api_logic';
+
+describe('FetchSyncJobs', () => {
+ const { http } = mockHttpValues;
+ beforeEach(() => {
+ jest.clearAllMocks();
+ });
+ describe('fetchSyncJobs', () => {
+ it('calls correct api', async () => {
+ const promise = Promise.resolve('result');
+ http.get.mockReturnValue(promise);
+ const result = fetchSyncJobs({ connectorId: 'connectorId1' });
+ await nextTick();
+ expect(http.get).toHaveBeenCalledWith(
+ '/internal/enterprise_search/connectors/connectorId1/sync_jobs',
+ { query: { page: 0, size: 10 } }
+ );
+ await expect(result).resolves.toEqual('result');
+ });
+ it('appends query if specified', async () => {
+ const promise = Promise.resolve('result');
+ http.get.mockReturnValue(promise);
+ const result = fetchSyncJobs({ connectorId: 'connectorId1', page: 10, size: 20 });
+ await nextTick();
+ expect(http.get).toHaveBeenCalledWith(
+ '/internal/enterprise_search/connectors/connectorId1/sync_jobs',
+ { query: { page: 10, size: 20 } }
+ );
+ await expect(result).resolves.toEqual('result');
+ });
+ });
+});
diff --git a/x-pack/plugins/enterprise_search/public/applications/enterprise_search_content/api/connector/fetch_sync_jobs_api_logic.ts b/x-pack/plugins/enterprise_search/public/applications/enterprise_search_content/api/connector/fetch_sync_jobs_api_logic.ts
new file mode 100644
index 0000000000000..a45bf5e0943ca
--- /dev/null
+++ b/x-pack/plugins/enterprise_search/public/applications/enterprise_search_content/api/connector/fetch_sync_jobs_api_logic.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 { ConnectorSyncJob } from '../../../../../common/types/connectors';
+import { Paginate } from '../../../../../common/types/pagination';
+
+import { createApiLogic } from '../../../shared/api_logic/create_api_logic';
+import { HttpLogic } from '../../../shared/http';
+
+export interface FetchSyncJobsArgs {
+ connectorId: string;
+ page?: number;
+ size?: number;
+}
+
+export type FetchSyncJobsResponse = Paginate;
+
+export const fetchSyncJobs = async ({ connectorId, page = 0, size = 10 }: FetchSyncJobsArgs) => {
+ const route = `/internal/enterprise_search/connectors/${connectorId}/sync_jobs`;
+ const query = { page, size };
+ return await HttpLogic.values.http.get>(route, { query });
+};
+
+export const FetchSyncJobsApiLogic = createApiLogic(
+ ['enterprise_search_content', 'fetch_sync_api_logic'],
+ fetchSyncJobs
+);
diff --git a/x-pack/plugins/enterprise_search/public/applications/enterprise_search_content/components/search_index/index_view_logic.test.ts b/x-pack/plugins/enterprise_search/public/applications/enterprise_search_content/components/search_index/index_view_logic.test.ts
index 36a3e5b664ac9..e09b66051e4aa 100644
--- a/x-pack/plugins/enterprise_search/public/applications/enterprise_search_content/components/search_index/index_view_logic.test.ts
+++ b/x-pack/plugins/enterprise_search/public/applications/enterprise_search_content/components/search_index/index_view_logic.test.ts
@@ -26,6 +26,7 @@ import { IndexViewLogic } from './index_view_logic';
// We can't test fetchTimeOutId because this will get set whenever the logic is created
// And the timeoutId is non-deterministic. We use expect.object.containing throughout this test file
const DEFAULT_VALUES = {
+ connectorId: null,
data: undefined,
index: undefined,
indexName: '',
@@ -41,6 +42,7 @@ const DEFAULT_VALUES = {
const CONNECTOR_VALUES = {
...DEFAULT_VALUES,
+ connectorId: connectorIndex.connector.id,
data: connectorIndex,
index: indexToViewIndex(connectorIndex),
ingestionMethod: IngestionMethod.CONNECTOR,
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 4ed88ffe7ba8c..e49745dacfcb7 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
@@ -29,6 +29,7 @@ import {
getLastUpdated,
indexToViewIndex,
isConnectorIndex,
+ isConnectorViewIndex,
isCrawlerIndex,
} from '../../utils/indices';
@@ -61,6 +62,7 @@ export interface IndexViewActions {
}
export interface IndexViewValues {
+ connectorId: string | null;
data: typeof FetchIndexApiLogic.values.data;
fetchIndexTimeoutId: NodeJS.Timeout | null;
index: ElasticsearchViewIndex | undefined;
@@ -170,7 +172,7 @@ export const IndexViewLogic = kea {
if (isConnectorIndex(values.data)) {
- actions.makeStartSyncRequest({ connectorId: values.data?.connector?.id });
+ actions.makeStartSyncRequest({ connectorId: values.data.connector.id });
}
},
startSyncApiError: (e) => flashAPIErrors(e),
@@ -215,6 +217,10 @@ export const IndexViewLogic = kea ({
+ connectorId: [
+ () => [selectors.index],
+ (index) => (isConnectorViewIndex(index) ? index.connector.id : null),
+ ],
index: [() => [selectors.data], (data) => (data ? indexToViewIndex(data) : undefined)],
ingestionMethod: [() => [selectors.data], (data) => getIngestionMethod(data)],
ingestionStatus: [() => [selectors.data], (data) => getIngestionStatus(data)],
diff --git a/x-pack/plugins/enterprise_search/public/applications/enterprise_search_content/components/search_index/overview.tsx b/x-pack/plugins/enterprise_search/public/applications/enterprise_search_content/components/search_index/overview.tsx
index bcbc2847ff3e1..c0b392b646626 100644
--- a/x-pack/plugins/enterprise_search/public/applications/enterprise_search_content/components/search_index/overview.tsx
+++ b/x-pack/plugins/enterprise_search/public/applications/enterprise_search_content/components/search_index/overview.tsx
@@ -21,6 +21,7 @@ import { CrawlRequestsPanel } from './crawler/crawl_requests_panel/crawl_request
import { CrawlerTotalStats } from './crawler_total_stats';
import { GenerateApiKeyPanel } from './generate_api_key_panel';
import { OverviewLogic } from './overview.logic';
+import { SyncJobs } from './sync_jobs';
import { TotalStats } from './total_stats';
export const SearchIndexOverview: React.FC = () => {
@@ -67,6 +68,8 @@ export const SearchIndexOverview: React.FC = () => {
<>
+
+
>
)}
>
diff --git a/x-pack/plugins/enterprise_search/public/applications/enterprise_search_content/components/search_index/sync_jobs.tsx b/x-pack/plugins/enterprise_search/public/applications/enterprise_search_content/components/search_index/sync_jobs.tsx
new file mode 100644
index 0000000000000..708f8a6a77253
--- /dev/null
+++ b/x-pack/plugins/enterprise_search/public/applications/enterprise_search_content/components/search_index/sync_jobs.tsx
@@ -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 React, { useEffect } from 'react';
+
+import { useActions, useValues } from 'kea';
+
+import { EuiBadge, EuiBasicTable, EuiBasicTableColumn } from '@elastic/eui';
+
+import { i18n } from '@kbn/i18n';
+
+import { SyncStatus } from '../../../../../common/types/connectors';
+
+import { FormattedDateTime } from '../../../shared/formatted_date_time';
+import { durationToText } from '../../utils/duration_to_text';
+
+import { syncStatusToColor, syncStatusToText } from '../../utils/sync_status_to_text';
+
+import { IndexViewLogic } from './index_view_logic';
+import { SyncJobsViewLogic, SyncJobView } from './sync_jobs_view_logic';
+
+export const SyncJobs: React.FC = () => {
+ const { connectorId } = useValues(IndexViewLogic);
+ const { syncJobs, syncJobsLoading, syncJobsPagination } = useValues(SyncJobsViewLogic);
+ const { fetchSyncJobs } = useActions(SyncJobsViewLogic);
+
+ useEffect(() => {
+ if (connectorId) {
+ fetchSyncJobs({
+ connectorId,
+ page: syncJobsPagination.pageIndex ?? 0,
+ size: syncJobsPagination.pageSize ?? 10,
+ });
+ }
+ }, [connectorId]);
+
+ const columns: Array> = [
+ {
+ field: 'lastSync',
+ name: i18n.translate('xpack.enterpriseSearch.content.syncJobs.lastSync.columnTitle', {
+ defaultMessage: 'Last sync',
+ }),
+ render: (lastSync: string) => ,
+ sortable: true,
+ truncateText: true,
+ width: '25%',
+ },
+ {
+ field: 'duration',
+ name: i18n.translate('xpack.enterpriseSearch.content.syncJobs.syncDuration.columnTitle', {
+ defaultMessage: 'Sync duration',
+ }),
+ render: (duration: moment.Duration) => durationToText(duration),
+ sortable: true,
+ truncateText: true,
+ width: '25%',
+ },
+ {
+ field: 'docsCount',
+ name: i18n.translate('xpack.enterpriseSearch.content.searchIndices.docsCount.columnTitle', {
+ defaultMessage: 'Docs count',
+ }),
+ sortable: true,
+ truncateText: true,
+ width: '25%',
+ },
+ {
+ field: 'status',
+ name: i18n.translate('xpack.enterpriseSearch.content.searchIndices.syncStatus.columnTitle', {
+ defaultMessage: 'Status',
+ }),
+ render: (syncStatus: SyncStatus) => (
+ {syncStatusToText(syncStatus)}
+ ),
+ truncateText: true,
+ width: '25%',
+ },
+ ];
+
+ return (
+ {
+ if (connectorId) {
+ fetchSyncJobs({ connectorId, page: index, size: syncJobsPagination.pageSize });
+ }
+ }}
+ pagination={{
+ ...syncJobsPagination,
+ totalItemCount: syncJobsPagination.total,
+ }}
+ tableLayout="fixed"
+ loading={syncJobsLoading}
+ />
+ );
+};
diff --git a/x-pack/plugins/enterprise_search/public/applications/enterprise_search_content/components/search_index/sync_jobs_view_logic.test.ts b/x-pack/plugins/enterprise_search/public/applications/enterprise_search_content/components/search_index/sync_jobs_view_logic.test.ts
new file mode 100644
index 0000000000000..52526abbfcef4
--- /dev/null
+++ b/x-pack/plugins/enterprise_search/public/applications/enterprise_search_content/components/search_index/sync_jobs_view_logic.test.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; you may not use this file except in compliance with the Elastic License
+ * 2.0.
+ */
+
+import { LogicMounter, mockFlashMessageHelpers } from '../../../__mocks__/kea_logic';
+
+import moment from 'moment';
+
+import { nextTick } from '@kbn/test-jest-helpers';
+
+import { HttpError, Status } from '../../../../../common/types/api';
+
+import { SyncStatus } from '../../../../../common/types/connectors';
+import { FetchSyncJobsApiLogic } from '../../api/connector/fetch_sync_jobs_api_logic';
+
+import { IndexViewLogic } from './index_view_logic';
+import { SyncJobView, SyncJobsViewLogic } from './sync_jobs_view_logic';
+
+// We can't test fetchTimeOutId because this will get set whenever the logic is created
+// And the timeoutId is non-deterministic. We use expect.object.containing throughout this test file
+const DEFAULT_VALUES = {
+ connectorId: null,
+ syncJobs: [],
+ syncJobsData: undefined,
+ syncJobsLoading: true,
+ syncJobsPagination: {
+ data: [],
+ has_more_hits_than_total: false,
+ pageIndex: 0,
+ pageSize: 10,
+ size: 0,
+ total: 0,
+ },
+ syncJobsStatus: Status.IDLE,
+};
+
+describe('SyncJobsViewLogic', () => {
+ const { mount: indexViewLogicMount } = new LogicMounter(IndexViewLogic);
+ const { mount: fetchSyncJobsMount } = new LogicMounter(FetchSyncJobsApiLogic);
+ const { mount } = new LogicMounter(SyncJobsViewLogic);
+
+ beforeEach(() => {
+ indexViewLogicMount();
+ fetchSyncJobsMount();
+ mount();
+ });
+
+ it('has expected default values', () => {
+ expect(SyncJobsViewLogic.values).toEqual(DEFAULT_VALUES);
+ });
+
+ describe('actions', () => {
+ describe('FetchIndexApiLogic.apiSuccess', () => {
+ const syncJob = {
+ completed_at: '2022-09-05T15:59:39.816+00:00',
+ connector_id: 'we2284IBjobuR2-lAuXh',
+ created_at: '2022-09-05T14:59:39.816+00:00',
+ deleted_document_count: 20,
+ error: null,
+ index_name: 'indexName',
+ indexed_document_count: 50,
+ status: SyncStatus.COMPLETED,
+ worker_hostname: 'hostname_fake',
+ };
+ const syncJobView: SyncJobView = {
+ docsCount: 30,
+ duration: moment.duration(1, 'hour'),
+ lastSync: syncJob.completed_at,
+ status: SyncStatus.COMPLETED,
+ };
+ it('should update values', async () => {
+ FetchSyncJobsApiLogic.actions.apiSuccess({
+ data: [syncJob],
+ has_more_hits_than_total: false,
+ pageIndex: 3,
+ pageSize: 20,
+ size: 20,
+ total: 50,
+ });
+ await nextTick();
+ expect(SyncJobsViewLogic.values).toEqual({
+ ...DEFAULT_VALUES,
+ syncJobs: [syncJobView],
+ syncJobsData: {
+ data: [syncJob],
+ has_more_hits_than_total: false,
+ pageIndex: 3,
+ pageSize: 20,
+ size: 20,
+ total: 50,
+ },
+ syncJobsLoading: false,
+ syncJobsPagination: {
+ has_more_hits_than_total: false,
+ pageIndex: 3,
+ pageSize: 20,
+ size: 20,
+ total: 50,
+ },
+ syncJobsStatus: Status.SUCCESS,
+ });
+ });
+ it('should update values for incomplete job', async () => {
+ FetchSyncJobsApiLogic.actions.apiSuccess({
+ data: [
+ {
+ ...syncJob,
+ completed_at: null,
+ deleted_document_count: 0,
+ status: SyncStatus.IN_PROGRESS,
+ },
+ ],
+ has_more_hits_than_total: false,
+ pageIndex: 3,
+ pageSize: 20,
+ size: 20,
+ total: 50,
+ });
+ await nextTick();
+ expect(SyncJobsViewLogic.values).toEqual({
+ ...DEFAULT_VALUES,
+ syncJobs: [
+ {
+ docsCount: 50,
+ duration: undefined,
+ lastSync: syncJob.created_at,
+ status: SyncStatus.IN_PROGRESS,
+ },
+ ],
+ syncJobsData: {
+ data: [
+ {
+ ...syncJob,
+ completed_at: null,
+ deleted_document_count: 0,
+ status: SyncStatus.IN_PROGRESS,
+ },
+ ],
+ has_more_hits_than_total: false,
+ pageIndex: 3,
+ pageSize: 20,
+ size: 20,
+ total: 50,
+ },
+ syncJobsLoading: false,
+ syncJobsPagination: {
+ has_more_hits_than_total: false,
+ pageIndex: 3,
+ pageSize: 20,
+ size: 20,
+ total: 50,
+ },
+ syncJobsStatus: Status.SUCCESS,
+ });
+ });
+ });
+ });
+
+ describe('listeners', () => {
+ it('calls clearFlashMessages on fetchSyncJobs', async () => {
+ SyncJobsViewLogic.actions.fetchSyncJobs({ connectorId: 'connectorId' });
+ await nextTick();
+ expect(mockFlashMessageHelpers.clearFlashMessages).toHaveBeenCalledTimes(1);
+ });
+
+ it('calls flashAPIErrors on apiError', async () => {
+ SyncJobsViewLogic.actions.fetchSyncJobsError({} as HttpError);
+ await nextTick();
+ expect(mockFlashMessageHelpers.flashAPIErrors).toHaveBeenCalledTimes(1);
+ expect(mockFlashMessageHelpers.flashAPIErrors).toHaveBeenCalledWith({});
+ expect(SyncJobsViewLogic.values).toEqual({
+ ...DEFAULT_VALUES,
+ syncJobsLoading: false,
+ syncJobsStatus: Status.ERROR,
+ });
+ });
+ });
+});
diff --git a/x-pack/plugins/enterprise_search/public/applications/enterprise_search_content/components/search_index/sync_jobs_view_logic.ts b/x-pack/plugins/enterprise_search/public/applications/enterprise_search_content/components/search_index/sync_jobs_view_logic.ts
new file mode 100644
index 0000000000000..0b2dff7d6d5eb
--- /dev/null
+++ b/x-pack/plugins/enterprise_search/public/applications/enterprise_search_content/components/search_index/sync_jobs_view_logic.ts
@@ -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; you may not use this file except in compliance with the Elastic License
+ * 2.0.
+ */
+
+import { kea, MakeLogicType } from 'kea';
+
+import moment from 'moment';
+
+import { Status } from '../../../../../common/types/api';
+
+import { ConnectorSyncJob, SyncStatus } from '../../../../../common/types/connectors';
+import { Paginate } from '../../../../../common/types/pagination';
+import { Actions } from '../../../shared/api_logic/create_api_logic';
+import { clearFlashMessages, flashAPIErrors } from '../../../shared/flash_messages';
+import {
+ FetchSyncJobsApiLogic,
+ FetchSyncJobsArgs,
+ FetchSyncJobsResponse,
+} from '../../api/connector/fetch_sync_jobs_api_logic';
+
+import { IndexViewLogic } from './index_view_logic';
+
+export interface SyncJobView {
+ docsCount: number;
+ duration: moment.Duration;
+ lastSync: string;
+ status: SyncStatus;
+}
+
+export interface IndexViewActions {
+ fetchSyncJobs: Actions['makeRequest'];
+ fetchSyncJobsError: Actions['apiError'];
+}
+
+export interface IndexViewValues {
+ connectorId: string | null;
+ syncJobs: SyncJobView[];
+ syncJobsData: Paginate | null;
+ syncJobsLoading: boolean;
+ syncJobsPagination: Paginate;
+ syncJobsStatus: Status;
+}
+
+export const SyncJobsViewLogic = kea>({
+ actions: {},
+ connect: {
+ actions: [
+ FetchSyncJobsApiLogic,
+ [
+ 'apiError as fetchSyncJobsError',
+ 'apiReset as resetFetchSyncJobsIndexApi',
+ 'apiSuccess as fetchSyncJobsApiSuccess',
+ 'makeRequest as fetchSyncJobs',
+ ],
+ ],
+ values: [
+ IndexViewLogic,
+ ['connectorId'],
+ FetchSyncJobsApiLogic,
+ ['data as syncJobsData', 'status as syncJobsStatus'],
+ ],
+ },
+ listeners: () => ({
+ fetchSyncJobs: () => clearFlashMessages(),
+ fetchSyncJobsError: (e) => flashAPIErrors(e),
+ }),
+ path: ['enterprise_search', 'content', 'sync_jobs_view_logic'],
+ selectors: ({ selectors }) => ({
+ syncJobs: [
+ () => [selectors.syncJobsData],
+ (data?: Paginate) =>
+ data?.data.map((syncJob) => {
+ return {
+ docsCount: syncJob.deleted_document_count
+ ? syncJob.indexed_document_count - syncJob.deleted_document_count
+ : syncJob.indexed_document_count,
+ duration: syncJob.completed_at
+ ? moment.duration(moment(syncJob.completed_at).diff(moment(syncJob.created_at)))
+ : undefined,
+ lastSync: syncJob.completed_at ?? syncJob.created_at,
+ status: syncJob.status,
+ };
+ }) ?? [],
+ ],
+ syncJobsLoading: [
+ () => [selectors.syncJobsStatus],
+ (status: Status) => status === Status.IDLE || status === Status.LOADING,
+ ],
+ syncJobsPagination: [
+ () => [selectors.syncJobsData],
+ (data?: Paginate) =>
+ data
+ ? { ...data, data: undefined }
+ : {
+ data: [],
+ has_more_hits_than_total: false,
+ pageIndex: 0,
+ pageSize: 10,
+ size: 0,
+ total: 0,
+ },
+ ],
+ }),
+});
diff --git a/x-pack/plugins/enterprise_search/public/applications/enterprise_search_content/utils/duration_to_text.test.ts b/x-pack/plugins/enterprise_search/public/applications/enterprise_search_content/utils/duration_to_text.test.ts
new file mode 100644
index 0000000000000..7615332b68959
--- /dev/null
+++ b/x-pack/plugins/enterprise_search/public/applications/enterprise_search_content/utils/duration_to_text.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; you may not use this file except in compliance with the Elastic License
+ * 2.0.
+ */
+
+import moment from 'moment';
+
+import { durationToText } from './duration_to_text';
+
+describe('durationToText', () => {
+ it('should correctly turn duration into text', () => {
+ expect(durationToText(moment.duration(11005, 'seconds'))).toEqual('3h 3m 25s');
+ });
+ it('should return -- for undefined', () => {
+ expect(durationToText(undefined)).toEqual('--');
+ });
+});
diff --git a/x-pack/plugins/enterprise_search/public/applications/enterprise_search_content/utils/duration_to_text.ts b/x-pack/plugins/enterprise_search/public/applications/enterprise_search_content/utils/duration_to_text.ts
new file mode 100644
index 0000000000000..e4d678666c75e
--- /dev/null
+++ b/x-pack/plugins/enterprise_search/public/applications/enterprise_search_content/utils/duration_to_text.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 moment from 'moment';
+
+export function durationToText(input?: moment.Duration): string {
+ if (input) {
+ const hours = input.hours();
+ const minutes = input.minutes();
+ const seconds = input.seconds();
+ return `${hours}h ${minutes}m ${seconds}s`;
+ } else {
+ return '--';
+ }
+}
diff --git a/x-pack/plugins/enterprise_search/public/applications/enterprise_search_content/utils/sync_status_to_text.test.ts b/x-pack/plugins/enterprise_search/public/applications/enterprise_search_content/utils/sync_status_to_text.test.ts
new file mode 100644
index 0000000000000..d9ecdf6ebc556
--- /dev/null
+++ b/x-pack/plugins/enterprise_search/public/applications/enterprise_search_content/utils/sync_status_to_text.test.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 { SyncStatus } from '../../../../common/types/connectors';
+
+import { syncStatusToColor, syncStatusToText } from './sync_status_to_text';
+
+describe('syncStatusToText', () => {
+ it('should return correct value for completed', () => {
+ expect(syncStatusToText(SyncStatus.COMPLETED)).toEqual('Sync complete');
+ });
+ it('should return correct value for error', () => {
+ expect(syncStatusToText(SyncStatus.ERROR)).toEqual('Sync failure');
+ });
+ it('should return correct value for in progress', () => {
+ expect(syncStatusToText(SyncStatus.IN_PROGRESS)).toEqual('Sync in progress');
+ });
+});
+
+describe('syncStatusToColor', () => {
+ it('should return correct value for completed', () => {
+ expect(syncStatusToColor(SyncStatus.COMPLETED)).toEqual('success');
+ });
+ it('should return correct value for error', () => {
+ expect(syncStatusToColor(SyncStatus.ERROR)).toEqual('danger');
+ });
+ it('should return correct value for in progress', () => {
+ expect(syncStatusToColor(SyncStatus.IN_PROGRESS)).toEqual('warning');
+ });
+});
diff --git a/x-pack/plugins/enterprise_search/public/applications/enterprise_search_content/utils/sync_status_to_text.ts b/x-pack/plugins/enterprise_search/public/applications/enterprise_search_content/utils/sync_status_to_text.ts
new file mode 100644
index 0000000000000..51d69f2e53ad7
--- /dev/null
+++ b/x-pack/plugins/enterprise_search/public/applications/enterprise_search_content/utils/sync_status_to_text.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 { i18n } from '@kbn/i18n';
+
+import { SyncStatus } from '../../../../common/types/connectors';
+
+export function syncStatusToText(status: SyncStatus): string {
+ switch (status) {
+ case SyncStatus.COMPLETED:
+ return i18n.translate('xpack.enterpriseSearch.content.syncStatus.completed', {
+ defaultMessage: 'Sync complete',
+ });
+ case SyncStatus.ERROR:
+ return i18n.translate('xpack.enterpriseSearch.content.syncStatus.error', {
+ defaultMessage: 'Sync failure',
+ });
+ case SyncStatus.IN_PROGRESS:
+ return i18n.translate('xpack.enterpriseSearch.content.syncStatus.inProgress', {
+ defaultMessage: 'Sync in progress',
+ });
+ }
+}
+
+export function syncStatusToColor(status: SyncStatus): string {
+ switch (status) {
+ case SyncStatus.COMPLETED:
+ return 'success';
+ case SyncStatus.ERROR:
+ return 'danger';
+ case SyncStatus.IN_PROGRESS:
+ return 'warning';
+ }
+}
diff --git a/x-pack/plugins/enterprise_search/server/__mocks__/fetch_indices.mock.ts b/x-pack/plugins/enterprise_search/server/__mocks__/fetch_indices.mock.ts
index a860069af9e93..bcdf0404e9ecf 100644
--- a/x-pack/plugins/enterprise_search/server/__mocks__/fetch_indices.mock.ts
+++ b/x-pack/plugins/enterprise_search/server/__mocks__/fetch_indices.mock.ts
@@ -11,6 +11,15 @@ export const mockSingleIndexResponse = {
},
};
+export const mockSingleIndexWithAliasesResponse = {
+ 'search-regular-index': {
+ aliases: {
+ 'search-alias-1': {},
+ 'search-alias-2': {},
+ },
+ },
+};
+
export const mockSingleIndexStatsResponse = {
indices: {
'search-regular-index': {
diff --git a/x-pack/plugins/enterprise_search/server/lib/analytics/add_analytics_collection.test.ts b/x-pack/plugins/enterprise_search/server/lib/analytics/add_analytics_collection.test.ts
index 7f8e8401a37d9..8289eaa3b2808 100644
--- a/x-pack/plugins/enterprise_search/server/lib/analytics/add_analytics_collection.test.ts
+++ b/x-pack/plugins/enterprise_search/server/lib/analytics/add_analytics_collection.test.ts
@@ -67,6 +67,18 @@ describe('add analytics collection lib function', () => {
expect(mockClient.asCurrentUser.index).not.toHaveBeenCalled();
});
+ it('should reject if collection name is invalid', async () => {
+ mockClient.asCurrentUser.index.mockImplementation(() => ({ _id: 'fakeId' }));
+ (fetchAnalyticsCollectionByName as jest.Mock).mockImplementation(() => false);
+
+ await expect(
+ addAnalyticsCollection(mockClient as unknown as IScopedClusterClient, {
+ name: 'index_name!',
+ })
+ ).rejects.toEqual(new Error(ErrorCode.ANALYTICS_COLLECTION_NAME_INVALID));
+ expect(mockClient.asCurrentUser.index).not.toHaveBeenCalled();
+ });
+
it('should create index if no analytics collection index exists', async () => {
mockClient.asCurrentUser.indices.exists.mockImplementation(() => false);
diff --git a/x-pack/plugins/enterprise_search/server/lib/analytics/add_analytics_collection.ts b/x-pack/plugins/enterprise_search/server/lib/analytics/add_analytics_collection.ts
index 1cad55a3e884c..aa5600c528340 100644
--- a/x-pack/plugins/enterprise_search/server/lib/analytics/add_analytics_collection.ts
+++ b/x-pack/plugins/enterprise_search/server/lib/analytics/add_analytics_collection.ts
@@ -8,8 +8,8 @@ import { IScopedClusterClient } from '@kbn/core/server';
import { ANALYTICS_COLLECTIONS_INDEX } from '../..';
import { AnalyticsCollectionDocument, AnalyticsCollection } from '../../../common/types/analytics';
-
import { ErrorCode } from '../../../common/types/error_codes';
+import { isAlphaNumericOrUnderscore } from '../../../common/utils/is_alphanumeric_underscore';
import { fetchAnalyticsCollectionByName } from './fetch_analytics_collection';
import { setupAnalyticsCollectionIndex } from './setup_indices';
@@ -24,6 +24,10 @@ const createAnalyticsCollection = async (
throw new Error(ErrorCode.ANALYTICS_COLLECTION_ALREADY_EXISTS);
}
+ if (!isAlphaNumericOrUnderscore(document.name)) {
+ throw new Error(ErrorCode.ANALYTICS_COLLECTION_NAME_INVALID);
+ }
+
// index the document
const result = await client.asCurrentUser.index({
document,
diff --git a/x-pack/plugins/enterprise_search/server/lib/connectors/add_connector.test.ts b/x-pack/plugins/enterprise_search/server/lib/connectors/add_connector.test.ts
index e74b5034d426d..42d0235cbd3a3 100644
--- a/x-pack/plugins/enterprise_search/server/lib/connectors/add_connector.test.ts
+++ b/x-pack/plugins/enterprise_search/server/lib/connectors/add_connector.test.ts
@@ -85,7 +85,8 @@ describe('addConnector lib function', () => {
});
expect(mockClient.asCurrentUser.indices.create).toHaveBeenCalledWith({
index: 'index_name',
- settings: textAnalysisSettings('fr'),
+ mappings: {},
+ settings: { ...textAnalysisSettings('fr'), auto_expand_replicas: '0-3', number_of_shards: 2 },
});
});
@@ -202,7 +203,12 @@ describe('addConnector lib function', () => {
});
expect(mockClient.asCurrentUser.indices.create).toHaveBeenCalledWith({
index: 'index_name',
- settings: textAnalysisSettings(undefined),
+ mappings: {},
+ settings: {
+ ...textAnalysisSettings(undefined),
+ auto_expand_replicas: '0-3',
+ number_of_shards: 2,
+ },
});
});
@@ -241,7 +247,8 @@ describe('addConnector lib function', () => {
});
expect(mockClient.asCurrentUser.indices.create).toHaveBeenCalledWith({
index: 'search-index_name',
- settings: textAnalysisSettings('en'),
+ mappings: {},
+ settings: { ...textAnalysisSettings('en'), auto_expand_replicas: '0-3', number_of_shards: 2 },
});
});
});
diff --git a/x-pack/plugins/enterprise_search/server/lib/connectors/add_connector.ts b/x-pack/plugins/enterprise_search/server/lib/connectors/add_connector.ts
index f673a98a987dd..f3275c0b2d73b 100644
--- a/x-pack/plugins/enterprise_search/server/lib/connectors/add_connector.ts
+++ b/x-pack/plugins/enterprise_search/server/lib/connectors/add_connector.ts
@@ -13,7 +13,7 @@ import { ErrorCode } from '../../../common/types/error_codes';
import { setupConnectorsIndices } from '../../index_management/setup_indices';
import { fetchCrawlerByIndexName } from '../crawler/fetch_crawlers';
-import { textAnalysisSettings } from '../indices/text_analysis';
+import { createIndex } from '../indices/create_index';
import { deleteConnectorById } from './delete_connector';
@@ -51,10 +51,7 @@ const createConnector = async (
document,
index: CONNECTORS_INDEX,
});
- await client.asCurrentUser.indices.create({
- index,
- settings: textAnalysisSettings(language ?? undefined),
- });
+ await createIndex(client, document.index_name, language, false);
await client.asCurrentUser.indices.refresh({ index: CONNECTORS_INDEX });
return { id: result._id, index_name: document.index_name };
diff --git a/x-pack/plugins/enterprise_search/server/lib/connectors/fetch_sync_jobs.test.ts b/x-pack/plugins/enterprise_search/server/lib/connectors/fetch_sync_jobs.test.ts
new file mode 100644
index 0000000000000..d06d9af1dbaf8
--- /dev/null
+++ b/x-pack/plugins/enterprise_search/server/lib/connectors/fetch_sync_jobs.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 { setupConnectorsIndices } from '../../index_management/setup_indices';
+
+import { fetchSyncJobsByConnectorId } from './fetch_sync_jobs';
+
+jest.mock('../../index_management/setup_indices', () => ({
+ setupConnectorsIndices: jest.fn(),
+}));
+
+describe('fetchSyncJobs lib', () => {
+ const mockClient = {
+ asCurrentUser: {
+ get: jest.fn(),
+ search: jest.fn(),
+ },
+ asInternalUser: {},
+ };
+
+ beforeEach(() => {
+ jest.clearAllMocks();
+ });
+ describe('fetch sync jobs by connector id', () => {
+ it('should fetch sync jobs by connector id', async () => {
+ mockClient.asCurrentUser.search.mockImplementationOnce(() =>
+ Promise.resolve({ hits: { hits: ['result1', 'result2'] }, total: 2 })
+ );
+ await expect(fetchSyncJobsByConnectorId(mockClient as any, 'id', 0, 10)).resolves.toEqual({
+ data: [],
+ has_more_hits_than_total: false,
+ pageIndex: 0,
+ pageSize: 10,
+ size: 0,
+ total: 0,
+ });
+ expect(mockClient.asCurrentUser.search).toHaveBeenCalledWith({
+ from: 0,
+ index: '.elastic-connectors-sync-jobs',
+ query: {
+ term: {
+ connector_id: 'id',
+ },
+ },
+ size: 10,
+ sort: {
+ created_at: {
+ order: 'desc',
+ },
+ },
+ });
+ });
+ it('should return empty result if size is 0', async () => {
+ await expect(fetchSyncJobsByConnectorId(mockClient as any, 'id', 0, 0)).resolves.toEqual({
+ data: [],
+ has_more_hits_than_total: false,
+ pageIndex: 0,
+ pageSize: 0,
+ size: 0,
+ total: 0,
+ });
+ expect(mockClient.asCurrentUser.search).not.toHaveBeenCalled();
+ });
+ it('should call setup connectors on index not found error', async () => {
+ mockClient.asCurrentUser.search.mockImplementationOnce(() =>
+ Promise.reject({
+ meta: {
+ body: {
+ error: {
+ type: 'index_not_found_exception',
+ },
+ },
+ },
+ })
+ );
+ await expect(fetchSyncJobsByConnectorId(mockClient as any, 'id', 0, 10)).resolves.toEqual({
+ data: [],
+ has_more_hits_than_total: false,
+ pageIndex: 0,
+ pageSize: 10,
+ size: 0,
+ total: 0,
+ });
+ expect(mockClient.asCurrentUser.search).toHaveBeenCalledWith({
+ from: 0,
+ index: '.elastic-connectors-sync-jobs',
+ query: {
+ term: {
+ connector_id: 'id',
+ },
+ },
+ size: 10,
+ sort: {
+ created_at: {
+ order: 'desc',
+ },
+ },
+ });
+ expect(setupConnectorsIndices as jest.Mock).toHaveBeenCalledWith(mockClient.asCurrentUser);
+ });
+ it('should not call setup connectors on other errors', async () => {
+ mockClient.asCurrentUser.search.mockImplementationOnce(() =>
+ Promise.reject({
+ meta: {
+ body: {
+ error: {
+ type: 'other error',
+ },
+ },
+ },
+ })
+ );
+ await expect(fetchSyncJobsByConnectorId(mockClient as any, 'id', 0, 10)).resolves.toEqual({
+ data: [],
+ has_more_hits_than_total: false,
+ pageIndex: 0,
+ pageSize: 10,
+ size: 0,
+ total: 0,
+ });
+ expect(mockClient.asCurrentUser.search).toHaveBeenCalledWith({
+ from: 0,
+ index: '.elastic-connectors-sync-jobs',
+ query: {
+ term: {
+ connector_id: 'id',
+ },
+ },
+ size: 10,
+ sort: {
+ created_at: {
+ order: 'desc',
+ },
+ },
+ });
+ expect(setupConnectorsIndices as jest.Mock).not.toHaveBeenCalled();
+ });
+ });
+});
diff --git a/x-pack/plugins/enterprise_search/server/lib/connectors/fetch_sync_jobs.ts b/x-pack/plugins/enterprise_search/server/lib/connectors/fetch_sync_jobs.ts
new file mode 100644
index 0000000000000..451b8e7ad3e6e
--- /dev/null
+++ b/x-pack/plugins/enterprise_search/server/lib/connectors/fetch_sync_jobs.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; you may not use this file except in compliance with the Elastic License
+ * 2.0.
+ */
+
+import { SearchTotalHits } from '@elastic/elasticsearch/lib/api/types';
+import { IScopedClusterClient } from '@kbn/core-elasticsearch-server';
+
+import { CONNECTORS_JOBS_INDEX } from '../..';
+import { ConnectorSyncJob } from '../../../common/types/connectors';
+import { Paginate } from '../../../common/types/pagination';
+import { isNotNullish } from '../../../common/utils/is_not_nullish';
+
+import { setupConnectorsIndices } from '../../index_management/setup_indices';
+import { isIndexNotFoundException } from '../../utils/identify_exceptions';
+
+export const fetchSyncJobsByConnectorId = async (
+ client: IScopedClusterClient,
+ connectorId: string,
+ pageIndex: number,
+ size: number
+): Promise> => {
+ try {
+ if (size === 0) {
+ // prevent some divide by zero errors below
+ return {
+ data: [],
+ has_more_hits_than_total: false,
+ pageIndex: 0,
+ pageSize: size,
+ size: 0,
+ total: 0,
+ };
+ }
+ const result = await client.asCurrentUser.search({
+ from: pageIndex * size,
+ index: CONNECTORS_JOBS_INDEX,
+ query: {
+ term: {
+ connector_id: connectorId,
+ },
+ },
+ size,
+ // @ts-ignore Elasticsearch-js has the wrong internal typing for this field
+ sort: { created_at: { order: 'desc' } },
+ });
+ const total = totalToPaginateTotal(result.hits.total);
+ // If we get fewer results than the target page, make sure we return correct page we're on
+ const resultPageIndex = Math.min(pageIndex, Math.trunc(total.total / size));
+ const data = result.hits.hits.map((hit) => hit._source).filter(isNotNullish) ?? [];
+ return {
+ data,
+ pageIndex: resultPageIndex,
+ pageSize: size,
+ size: data.length,
+ ...total,
+ };
+ } catch (error) {
+ if (isIndexNotFoundException(error)) {
+ await setupConnectorsIndices(client.asCurrentUser);
+ }
+ return {
+ data: [],
+ has_more_hits_than_total: false,
+ pageIndex: 0,
+ pageSize: size,
+ size: 0,
+ total: 0,
+ };
+ }
+};
+
+function totalToPaginateTotal(input: number | SearchTotalHits | undefined): {
+ has_more_hits_than_total: boolean;
+ total: number;
+} {
+ if (typeof input === 'number') {
+ return { has_more_hits_than_total: false, total: input };
+ }
+ return input
+ ? { has_more_hits_than_total: input.relation === 'gte' ? true : false, total: input.value }
+ : { has_more_hits_than_total: false, total: 0 };
+}
diff --git a/x-pack/plugins/enterprise_search/server/lib/indices/create_index.test.ts b/x-pack/plugins/enterprise_search/server/lib/indices/create_index.test.ts
index 877fbc1dcc12e..3e68960a68a5f 100644
--- a/x-pack/plugins/enterprise_search/server/lib/indices/create_index.test.ts
+++ b/x-pack/plugins/enterprise_search/server/lib/indices/create_index.test.ts
@@ -7,17 +7,63 @@
import { elasticsearchServiceMock } from '@kbn/core/server/mocks';
-import { createApiIndex } from './create_index';
+import { createIndex } from './create_index';
+import { textAnalysisSettings } from './text_analysis';
describe('createApiIndex lib function', () => {
const mockClient = elasticsearchServiceMock.createScopedClusterClient();
+ const defaultMappings = {
+ dynamic: true,
+ dynamic_templates: [
+ {
+ all_text_fields: {
+ mapping: {
+ analyzer: 'iq_text_base',
+ fields: {
+ delimiter: {
+ analyzer: 'iq_text_delimiter',
+ index_options: 'freqs',
+ type: 'text',
+ },
+ enum: {
+ ignore_above: 2048,
+ type: 'keyword',
+ },
+ joined: {
+ analyzer: 'i_text_bigram',
+ index_options: 'freqs',
+ search_analyzer: 'q_text_bigram',
+ type: 'text',
+ },
+ prefix: {
+ analyzer: 'i_prefix',
+ index_options: 'docs',
+ search_analyzer: 'q_prefix',
+ type: 'text',
+ },
+ stem: {
+ analyzer: 'iq_text_stem',
+ type: 'text',
+ },
+ },
+ },
+ match_mapping_type: 'string',
+ },
+ },
+ ],
+ };
+ const defaultSettings = {
+ auto_expand_replicas: '0-3',
+ number_of_shards: 2,
+ };
+
beforeEach(() => {
jest.clearAllMocks();
});
it('successfully creates an index', async () => {
- await expect(createApiIndex(mockClient, 'index_name', 'en')).resolves.toEqual({
+ await expect(createIndex(mockClient, 'index_name', 'en', true)).resolves.toEqual({
body: {},
headers: {
'x-elastic-product': 'Elasticsearch',
@@ -27,162 +73,25 @@ describe('createApiIndex lib function', () => {
warnings: [],
});
expect(mockClient.asCurrentUser.indices.create).toHaveBeenCalledWith({
- body: {
- mappings: {
- dynamic: true,
- dynamic_templates: [
- {
- all_text_fields: {
- mapping: {
- analyzer: 'iq_text_base',
- fields: {
- delimiter: {
- analyzer: 'iq_text_delimiter',
- index_options: 'freqs',
- type: 'text',
- },
- enum: {
- ignore_above: 2048,
- type: 'keyword',
- },
- joined: {
- analyzer: 'i_text_bigram',
- index_options: 'freqs',
- search_analyzer: 'q_text_bigram',
- type: 'text',
- },
- prefix: {
- analyzer: 'i_prefix',
- index_options: 'docs',
- search_analyzer: 'q_prefix',
- type: 'text',
- },
- stem: {
- analyzer: 'iq_text_stem',
- type: 'text',
- },
- },
- },
- match_mapping_type: 'string',
- },
- },
- ],
- },
- settings: {
- analysis: {
- analyzer: {
- i_prefix: {
- filter: ['cjk_width', 'lowercase', 'asciifolding', 'front_ngram'],
- tokenizer: 'standard',
- type: 'custom',
- },
- i_text_bigram: {
- filter: [
- 'cjk_width',
- 'lowercase',
- 'asciifolding',
- 'en-stem-filter',
- 'bigram_joiner',
- 'bigram_max_size',
- ],
- tokenizer: 'standard',
- type: 'custom',
- },
- iq_text_base: {
- filter: ['cjk_width', 'lowercase', 'asciifolding', 'en-stop-words-filter'],
- tokenizer: 'standard',
- type: 'custom',
- },
- iq_text_delimiter: {
- filter: [
- 'delimiter',
- 'cjk_width',
- 'lowercase',
- 'asciifolding',
- 'en-stop-words-filter',
- 'en-stem-filter',
- ],
- tokenizer: 'whitespace',
- type: 'custom',
- },
- iq_text_stem: {
- filter: [
- 'cjk_width',
- 'lowercase',
- 'asciifolding',
- 'en-stop-words-filter',
- 'en-stem-filter',
- ],
- tokenizer: 'standard',
- type: 'custom',
- },
- q_prefix: {
- filter: ['cjk_width', 'lowercase', 'asciifolding'],
- tokenizer: 'standard',
- type: 'custom',
- },
- q_text_bigram: {
- filter: [
- 'cjk_width',
- 'lowercase',
- 'asciifolding',
- 'en-stem-filter',
- 'bigram_joiner_unigrams',
- 'bigram_max_size',
- ],
- tokenizer: 'standard',
- type: 'custom',
- },
- },
- filter: {
- bigram_joiner: {
- max_shingle_size: 2,
- output_unigrams: false,
- token_separator: '',
- type: 'shingle',
- },
- bigram_joiner_unigrams: {
- max_shingle_size: 2,
- output_unigrams: true,
- token_separator: '',
- type: 'shingle',
- },
- bigram_max_size: {
- max: 16,
- min: 0,
- type: 'length',
- },
- delimiter: {
- catenate_all: true,
- catenate_numbers: true,
- catenate_words: true,
- generate_number_parts: true,
- generate_word_parts: true,
- preserve_original: false,
- split_on_case_change: true,
- split_on_numerics: true,
- stem_english_possessive: true,
- type: 'word_delimiter_graph',
- },
- 'en-stem-filter': {
- name: 'light_english',
- language: 'light_english',
- type: 'stemmer',
- },
- 'en-stop-words-filter': {
- stopwords: '_english_',
- type: 'stop',
- },
- front_ngram: {
- max_gram: 12,
- min_gram: 1,
- type: 'edge_ngram',
- },
- },
- },
- },
+ index: 'index_name',
+ mappings: defaultMappings,
+ settings: { ...textAnalysisSettings('en'), ...defaultSettings },
+ });
+ });
+ it('successfully creates an index with no mappings in French', async () => {
+ await expect(createIndex(mockClient, 'index_name', 'fr', false)).resolves.toEqual({
+ body: {},
+ headers: {
+ 'x-elastic-product': 'Elasticsearch',
},
+ meta: {},
+ statusCode: 200,
+ warnings: [],
+ });
+ expect(mockClient.asCurrentUser.indices.create).toHaveBeenCalledWith({
index: 'index_name',
+ mappings: {},
+ settings: { ...textAnalysisSettings('fr'), ...defaultSettings },
});
});
});
diff --git a/x-pack/plugins/enterprise_search/server/lib/indices/create_index.ts b/x-pack/plugins/enterprise_search/server/lib/indices/create_index.ts
index 1e3df81ab7963..1213cefd50602 100644
--- a/x-pack/plugins/enterprise_search/server/lib/indices/create_index.ts
+++ b/x-pack/plugins/enterprise_search/server/lib/indices/create_index.ts
@@ -61,16 +61,19 @@ const defaultMappings = {
],
};
-export const createApiIndex = async (
+export const createIndex = async (
client: IScopedClusterClient,
indexName: string,
- language: string | undefined | null
+ language: string | undefined | null,
+ applyMappings: boolean
) => {
return await client.asCurrentUser.indices.create({
- body: {
- mappings: defaultMappings,
- settings: textAnalysisSettings(language ?? undefined),
- },
index: indexName,
+ mappings: applyMappings ? defaultMappings : {},
+ settings: {
+ ...textAnalysisSettings(language ?? undefined),
+ auto_expand_replicas: '0-3',
+ number_of_shards: 2,
+ },
});
};
diff --git a/x-pack/plugins/enterprise_search/server/lib/indices/fetch_index.ts b/x-pack/plugins/enterprise_search/server/lib/indices/fetch_index.ts
index 2414e19de1183..140a1180360ed 100644
--- a/x-pack/plugins/enterprise_search/server/lib/indices/fetch_index.ts
+++ b/x-pack/plugins/enterprise_search/server/lib/indices/fetch_index.ts
@@ -12,7 +12,7 @@ import { ElasticsearchIndexWithIngestion } from '../../../common/types/indices';
import { fetchConnectorByIndexName } from '../connectors/fetch_connectors';
import { fetchCrawlerByIndexName } from '../crawler/fetch_crawlers';
-import { mapIndexStats } from './fetch_indices';
+import { mapIndexStats } from './utils/map_index_stats';
export const fetchIndex = async (
client: IScopedClusterClient,
diff --git a/x-pack/plugins/enterprise_search/server/lib/indices/fetch_index_counts.test.ts b/x-pack/plugins/enterprise_search/server/lib/indices/fetch_index_counts.test.ts
new file mode 100644
index 0000000000000..248b50eb6f0ee
--- /dev/null
+++ b/x-pack/plugins/enterprise_search/server/lib/indices/fetch_index_counts.test.ts
@@ -0,0 +1,30 @@
+/*
+ * 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 { IScopedClusterClient } from '@kbn/core/server';
+
+import { fetchIndexCounts } from './fetch_index_counts';
+
+describe('fetchIndexCounts lib function', () => {
+ const mockClient = {
+ asCurrentUser: {
+ count: jest.fn().mockReturnValue({ count: 100 }),
+ },
+ };
+
+ it('returns count api response for each index name provided', async () => {
+ const indexNames = ['index1', 'index2', 'index3'];
+
+ await expect(
+ fetchIndexCounts(mockClient as unknown as IScopedClusterClient, indexNames)
+ ).resolves.toEqual({
+ index1: 100,
+ index2: 100,
+ index3: 100,
+ });
+ });
+});
diff --git a/x-pack/plugins/enterprise_search/server/lib/indices/fetch_index_counts.ts b/x-pack/plugins/enterprise_search/server/lib/indices/fetch_index_counts.ts
new file mode 100644
index 0000000000000..a80deebe45761
--- /dev/null
+++ b/x-pack/plugins/enterprise_search/server/lib/indices/fetch_index_counts.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 { IScopedClusterClient } from '@kbn/core/server';
+
+export const fetchIndexCounts = async (client: IScopedClusterClient, indicesNames: string[]) => {
+ // TODO: is there way to batch this? Passing multiple index names or a pattern still returns a singular count
+ const countPromises = indicesNames.map(async (indexName) => {
+ const { count } = await client.asCurrentUser.count({ index: indexName });
+ return { [indexName]: count };
+ });
+ const indexCountArray = await Promise.all(countPromises);
+ return indexCountArray.reduce((acc, current) => ({ ...acc, ...current }), {});
+};
diff --git a/x-pack/plugins/enterprise_search/server/lib/indices/fetch_index_privileges.test.ts b/x-pack/plugins/enterprise_search/server/lib/indices/fetch_index_privileges.test.ts
new file mode 100644
index 0000000000000..f7cf7222977c6
--- /dev/null
+++ b/x-pack/plugins/enterprise_search/server/lib/indices/fetch_index_privileges.test.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 { IScopedClusterClient } from '@kbn/core/server';
+
+import { fetchIndexPrivileges } from './fetch_index_privileges';
+
+describe('fetchIndexPrivileges lib function', () => {
+ const mockClient = {
+ asCurrentUser: {
+ security: {
+ hasPrivileges: jest.fn(),
+ },
+ },
+ };
+
+ it('returns read, manage privileges for index and alias names provided', async () => {
+ mockClient.asCurrentUser.security.hasPrivileges.mockImplementation(() => ({
+ index: {
+ index1: { manage: true, read: true },
+ index2: { manage: false, read: true },
+ },
+ }));
+
+ const indexAndAliasNames = ['index1', 'index2'];
+
+ await expect(
+ fetchIndexPrivileges(mockClient as unknown as IScopedClusterClient, indexAndAliasNames)
+ ).resolves.toEqual({
+ index1: { manage: true, read: true },
+ index2: { manage: false, read: true },
+ });
+ });
+});
diff --git a/x-pack/plugins/enterprise_search/server/lib/indices/fetch_index_privileges.ts b/x-pack/plugins/enterprise_search/server/lib/indices/fetch_index_privileges.ts
new file mode 100644
index 0000000000000..e640acc4f4ffb
--- /dev/null
+++ b/x-pack/plugins/enterprise_search/server/lib/indices/fetch_index_privileges.ts
@@ -0,0 +1,24 @@
+/*
+ * 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 { IScopedClusterClient } from '@kbn/core/server';
+
+export const fetchIndexPrivileges = async (
+ client: IScopedClusterClient,
+ indexAndAliasNames: string[]
+) => {
+ // TODO: make multiple batched requests if indicesNames.length > SOMETHING
+ const { index: indexPrivileges } = await client.asCurrentUser.security.hasPrivileges({
+ index: [
+ {
+ names: indexAndAliasNames,
+ privileges: ['read', 'manage'],
+ },
+ ],
+ });
+ return indexPrivileges;
+};
diff --git a/x-pack/plugins/enterprise_search/server/lib/indices/fetch_index_stats.test.ts b/x-pack/plugins/enterprise_search/server/lib/indices/fetch_index_stats.test.ts
new file mode 100644
index 0000000000000..56eabaa9d6fa7
--- /dev/null
+++ b/x-pack/plugins/enterprise_search/server/lib/indices/fetch_index_stats.test.ts
@@ -0,0 +1,86 @@
+/*
+ * 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 { ByteSizeValue } from '@kbn/config-schema';
+import { IScopedClusterClient } from '@kbn/core-elasticsearch-server';
+
+import { fetchIndexStats } from './fetch_index_stats';
+
+describe('fetchIndexStats lib function', () => {
+ const mockClient = {
+ asCurrentUser: {
+ indices: {
+ stats: jest.fn(),
+ },
+ },
+ asInternalUser: {},
+ };
+
+ const indexStatsResponse = {
+ indices: {
+ 'search-regular-index': {
+ health: 'green',
+ size: new ByteSizeValue(108000).toString(),
+ status: 'open',
+ total: {
+ docs: {
+ count: 100,
+ deleted: 0,
+ },
+ store: {
+ size_in_bytes: 108000,
+ },
+ },
+ uuid: '83a81e7e-5955-4255-b008-5d6961203f57',
+ },
+ },
+ };
+
+ it('returns stats from stats api with correct configuration', async () => {
+ mockClient.asCurrentUser.indices.stats.mockImplementation(() => indexStatsResponse);
+
+ await expect(
+ fetchIndexStats(mockClient as unknown as IScopedClusterClient, '*', ['open'])
+ ).resolves.toEqual({
+ ...indexStatsResponse.indices,
+ });
+
+ expect(mockClient.asCurrentUser.indices.stats).toHaveBeenCalledWith({
+ expand_wildcards: ['open'],
+ index: '*',
+ metric: ['docs', 'store'],
+ });
+ });
+
+ it('returns empty object if response has no indices', async () => {
+ mockClient.asCurrentUser.indices.stats.mockImplementation(() => ({
+ error: {
+ index: 'indexName',
+ index_uuid: '_na_',
+ reason: 'no such index [indexName]',
+ 'resource.id': 'indexName',
+ 'resource.type': 'index_or_alias',
+ root_cause: [
+ {
+ index: 'indexName',
+ index_uuid: '_na_',
+ reason: 'no such index [indexName]',
+ 'resource.id': 'indexName',
+ 'resource.type': 'index_or_alias',
+ type: 'index_not_found_exception',
+ },
+ ],
+ type: 'index_not_found_exception',
+ },
+ status: 404,
+ }));
+
+ await expect(
+ fetchIndexStats(mockClient as unknown as IScopedClusterClient, '*', ['open'])
+ ).resolves.toEqual({});
+ });
+});
diff --git a/x-pack/plugins/enterprise_search/server/lib/indices/fetch_index_stats.ts b/x-pack/plugins/enterprise_search/server/lib/indices/fetch_index_stats.ts
new file mode 100644
index 0000000000000..6af10f3c73cff
--- /dev/null
+++ b/x-pack/plugins/enterprise_search/server/lib/indices/fetch_index_stats.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 { ExpandWildcard } from '@elastic/elasticsearch/lib/api/types';
+
+import { IScopedClusterClient } from '@kbn/core/server';
+
+export const fetchIndexStats = async (
+ client: IScopedClusterClient,
+ indexPattern: string,
+ expandWildcards: ExpandWildcard[]
+) => {
+ const { indices: indicesStats = {} } = await client.asCurrentUser.indices.stats({
+ expand_wildcards: expandWildcards,
+ index: indexPattern,
+ metric: ['docs', 'store'],
+ });
+ return indicesStats;
+};
diff --git a/x-pack/plugins/enterprise_search/server/lib/indices/fetch_indices.ts b/x-pack/plugins/enterprise_search/server/lib/indices/fetch_indices.ts
index 5a1bfec87b9b7..fd9180ba71130 100644
--- a/x-pack/plugins/enterprise_search/server/lib/indices/fetch_indices.ts
+++ b/x-pack/plugins/enterprise_search/server/lib/indices/fetch_indices.ts
@@ -5,59 +5,29 @@
* 2.0.
*/
+import { ExpandWildcard } from '@elastic/elasticsearch/lib/api/types';
import {
- ExpandWildcard,
- IndicesIndexState,
+ IndicesGetResponse,
+ SecurityHasPrivilegesPrivileges,
IndicesStatsIndicesStats,
-} from '@elastic/elasticsearch/lib/api/types';
-import { ByteSizeValue } from '@kbn/config-schema';
+} from '@elastic/elasticsearch/lib/api/typesWithBodyKey';
import { IScopedClusterClient } from '@kbn/core/server';
-import {
- ElasticsearchIndex,
- ElasticsearchIndexWithPrivileges,
-} from '../../../common/types/indices';
-
-export const mapIndexStats = (
- indexData: IndicesIndexState,
- indexStats: IndicesStatsIndicesStats,
- indexName: string
-): Omit & { aliases: string[] } => {
- const aliases = Object.keys(indexData.aliases!);
- const sizeInBytes = new ByteSizeValue(indexStats?.total?.store?.size_in_bytes ?? 0).toString();
-
- const docCount = indexStats?.total?.docs?.count ?? 0;
- const docDeleted = indexStats?.total?.docs?.deleted ?? 0;
- const total = {
- docs: {
- count: docCount,
- deleted: docDeleted,
- },
- store: {
- size_in_bytes: sizeInBytes,
- },
- };
+import { ElasticsearchIndexWithPrivileges } from '../../../common/types/indices';
- return {
- aliases,
- health: indexStats?.health,
- hidden: Boolean(indexData.settings?.index?.hidden),
- name: indexName,
- status: indexStats?.status,
- total,
- uuid: indexStats?.uuid,
- };
-};
+import { fetchIndexCounts } from './fetch_index_counts';
+import { fetchIndexPrivileges } from './fetch_index_privileges';
+import { fetchIndexStats } from './fetch_index_stats';
+import { expandAliases, getAlwaysShowAliases } from './utils/extract_always_show_indices';
+import { getIndexDataMapper } from './utils/get_index_data';
+import { getIndexData } from './utils/get_index_data';
-export const fetchIndexCounts = async (client: IScopedClusterClient, indicesNames: string[]) => {
- // TODO: is there way to batch this? Passing multiple index names or a pattern still returns a singular count
- const countPromises = indicesNames.map(async (indexName) => {
- const { count } = await client.asCurrentUser.count({ index: indexName });
- return { [indexName]: count };
- });
- const indexCountArray = await Promise.all(countPromises);
- return indexCountArray.reduce((acc, current) => ({ ...acc, ...current }), {});
-};
+export interface TotalIndexData {
+ allIndexMatches: IndicesGetResponse;
+ indexCounts: Record;
+ indexPrivileges: Record;
+ indicesStats: Record;
+}
export const fetchIndices = async (
client: IScopedClusterClient,
@@ -70,133 +40,63 @@ export const fetchIndices = async (
// If we provide an override pattern with alwaysShowSearchPattern we get everything and filter out hiddens.
const expandWildcards: ExpandWildcard[] =
returnHiddenIndices || alwaysShowSearchPattern ? ['hidden', 'all'] : ['open'];
- const totalIndices = await client.asCurrentUser.indices.get({
- expand_wildcards: expandWildcards,
- // for better performance only compute aliases and settings of indices but not mappings
- features: ['aliases', 'settings'],
- // only get specified index properties from ES to keep the response under 536MB
- // node.js string length limit: https://github.com/nodejs/node/issues/33960
- filter_path: ['*.aliases', '*.settings.index.hidden'],
- index: indexPattern,
- });
-
- // Index names that with one of their aliases match with the alwaysShowSearchPattern
- const alwaysShowPatternMatches = new Set();
-
- const indexAndAliasNames = Object.keys(totalIndices).reduce((accum, indexName) => {
- accum.push(indexName);
-
- if (includeAliases) {
- const aliases = Object.keys(totalIndices[indexName].aliases!);
- aliases.forEach((alias) => {
- accum.push(alias);
-
- // Add indexName to the set if an alias matches the pattern
- if (alwaysShowSearchPattern && alias.startsWith(alwaysShowSearchPattern)) {
- alwaysShowPatternMatches.add(indexName);
- }
- });
- }
- return accum;
- }, [] as string[]);
-
- const indicesNames = returnHiddenIndices
- ? Object.keys(totalIndices)
- : Object.keys(totalIndices).filter(
- (indexName) => !(totalIndices[indexName]?.settings?.index?.hidden === 'true')
- );
+
+ const { allIndexMatches, indexAndAliasNames, indicesNames, alwaysShowMatchNames } =
+ await getIndexData(
+ client,
+ indexPattern,
+ expandWildcards,
+ returnHiddenIndices,
+ includeAliases,
+ alwaysShowSearchPattern
+ );
+
if (indicesNames.length === 0) {
return [];
}
- const { indices: indicesStats = {} } = await client.asCurrentUser.indices.stats({
- expand_wildcards: expandWildcards,
- index: indexPattern,
- metric: ['docs', 'store'],
- });
-
- // TODO: make multiple batched requests if indicesNames.length > SOMETHING
- const { index: indexPrivileges } = await client.asCurrentUser.security.hasPrivileges({
- index: [
- {
- names: indexAndAliasNames,
- privileges: ['read', 'manage'],
- },
- ],
- });
+ const indicesStats = await fetchIndexStats(client, indexPattern, expandWildcards);
- const indexCounts = await fetchIndexCounts(client, indexAndAliasNames);
+ const indexPrivileges = await fetchIndexPrivileges(client, indexAndAliasNames);
- // Index data to show even if they are hidden, set by alwaysShowSearchPattern
- const alwaysShowIndices = alwaysShowSearchPattern
- ? Array.from(alwaysShowPatternMatches)
- .map((indexName: string) => {
- const indexData = totalIndices[indexName];
- const indexStats = indicesStats[indexName];
- return mapIndexStats(indexData, indexStats, indexName);
- })
- .flatMap(({ name, aliases, ...indexData }) => {
- const indicesAndAliases: ElasticsearchIndexWithPrivileges[] = [];
-
- if (includeAliases) {
- aliases.forEach((alias) => {
- if (alias.startsWith(alwaysShowSearchPattern)) {
- indicesAndAliases.push({
- ...indexData,
- alias: true,
- count: indexCounts[alias] ?? 0,
- name: alias,
- privileges: { manage: false, read: false, ...indexPrivileges[name] },
- });
- }
- });
- }
-
- return indicesAndAliases;
- })
- : [];
+ const indexCounts = await fetchIndexCounts(client, indexAndAliasNames);
+ const totalIndexData: TotalIndexData = {
+ allIndexMatches,
+ indexCounts,
+ indexPrivileges,
+ indicesStats,
+ };
const regularIndexData = indicesNames
- .map((indexName: string) => {
- const indexData = totalIndices[indexName];
- const indexStats = indicesStats[indexName];
- return mapIndexStats(indexData, indexStats, indexName);
- })
+ .map(getIndexDataMapper(totalIndexData))
.flatMap(({ name, aliases, ...indexData }) => {
// expand aliases and add to results
- const indicesAndAliases: ElasticsearchIndexWithPrivileges[] = [];
- indicesAndAliases.push({
+
+ const indexEntry = {
...indexData,
alias: false,
count: indexCounts[name] ?? 0,
name,
privileges: { manage: false, read: false, ...indexPrivileges[name] },
- });
-
- if (includeAliases) {
- aliases.forEach((alias) => {
- indicesAndAliases.push({
- ...indexData,
- alias: true,
- count: indexCounts[alias] ?? 0,
- name: alias,
- privileges: { manage: false, read: false, ...indexPrivileges[name] },
- });
- });
- }
- return indicesAndAliases;
+ };
+ return includeAliases
+ ? [indexEntry, ...expandAliases(name, aliases, indexData, totalIndexData)]
+ : [indexEntry];
});
- const indexNamesAlreadyIncluded = regularIndexData.map(({ name }) => name);
- const indexNamesToInclude = alwaysShowIndices
- .map(({ name }) => name)
- .filter((name) => !indexNamesAlreadyIncluded.includes(name));
+ let indicesData = regularIndexData;
+
+ if (alwaysShowSearchPattern && includeAliases) {
+ const indexNamesAlreadyIncluded = regularIndexData.map(({ name }) => name);
- const itemsToInclude = alwaysShowIndices.filter(({ name }) => indexNamesToInclude.includes(name));
+ const itemsToInclude = getAlwaysShowAliases(indexNamesAlreadyIncluded, alwaysShowMatchNames)
+ .map(getIndexDataMapper(totalIndexData))
+ .flatMap(({ name, aliases, ...indexData }) => {
+ return expandAliases(name, aliases, indexData, totalIndexData, alwaysShowSearchPattern);
+ });
- const indicesData = alwaysShowSearchPattern
- ? [...regularIndexData, ...itemsToInclude]
- : regularIndexData;
+ indicesData = [...indicesData, ...itemsToInclude];
+ }
return indicesData.filter(
({ name }, index, array) =>
diff --git a/x-pack/plugins/enterprise_search/server/lib/indices/text_analysis.ts b/x-pack/plugins/enterprise_search/server/lib/indices/text_analysis.ts
index 87f0b2cfca4ed..0885b00dd079e 100644
--- a/x-pack/plugins/enterprise_search/server/lib/indices/text_analysis.ts
+++ b/x-pack/plugins/enterprise_search/server/lib/indices/text_analysis.ts
@@ -8,12 +8,12 @@
import { AnalysisTokenFilter } from '@elastic/elasticsearch/lib/api/types';
interface LanguageDataEntry {
+ custom_filter_definitions?: object;
name: string;
stemmer: string;
stop_words: string;
- custom_filter_definitions?: object;
- prepended_filters?: string[];
postpended_filters?: string[];
+ prepended_filters?: string[];
}
const languageData: Record = {
@@ -282,13 +282,13 @@ const filterDefinitions = (language: string) => {
return {
...genericFilters,
[stemFilterName(language)]: {
- type: 'stemmer' as const,
- name: stemmerName,
language: stemmerName,
+ name: stemmerName,
+ type: 'stemmer' as const,
},
[stopWordsFilterName(language)]: {
- type: 'stop' as const,
stopwords: stopWordsName,
+ type: 'stop' as const,
},
...customFilterDefinitions,
};
diff --git a/x-pack/plugins/enterprise_search/server/lib/indices/utils/extract_always_show_indices.test.ts b/x-pack/plugins/enterprise_search/server/lib/indices/utils/extract_always_show_indices.test.ts
new file mode 100644
index 0000000000000..927109359c31e
--- /dev/null
+++ b/x-pack/plugins/enterprise_search/server/lib/indices/utils/extract_always_show_indices.test.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 { SecurityHasPrivilegesPrivileges } from '@elastic/elasticsearch/lib/api/typesWithBodyKey';
+
+import { ElasticsearchIndex } from '../../../../common/types/indices';
+
+import { expandAliases, getAlwaysShowAliases } from './extract_always_show_indices';
+
+describe('getAlwaysShowAliases util function', () => {
+ it('returns empty array if names that match with override pattern is empty', () => {
+ const mockIndexAndAliasNames: string[] = ['index-1', 'alias-1', 'index-2', 'alias-2'];
+ const mockAlwaysShowNames: string[] = [];
+
+ const aliases = getAlwaysShowAliases(mockIndexAndAliasNames, mockAlwaysShowNames);
+
+ expect(aliases).toEqual([]);
+ });
+
+ it('returns names that are NOT already included with index and alias names', () => {
+ const mockIndexAndAliasNames: string[] = ['index-1', 'alias-1', 'index-2', 'alias-2'];
+ const mockAlwaysShowNames: string[] = ['index-1', 'search-not-included'];
+
+ const aliases = getAlwaysShowAliases(mockIndexAndAliasNames, mockAlwaysShowNames);
+
+ expect(aliases).toEqual(['search-not-included']);
+ });
+});
+
+describe('expandAliases util function', () => {
+ const mockIndexName = 'mock-index';
+ const mockAliases = ['alias-1', 'search-alias-2', 'alias-with-missing-data'];
+ const mockIndex: Omit = {
+ hidden: false,
+ total: {
+ docs: {
+ count: 200, // Lucene count
+ deleted: 0,
+ },
+ store: {
+ size_in_bytes: '100Kb',
+ },
+ },
+ };
+
+ const mockIndicesData: {
+ indexCounts: Record;
+ indexPrivileges: Record;
+ } = {
+ indexCounts: { 'alias-1': 100, 'search-alias-2': 100 },
+ indexPrivileges: {
+ 'alias-1': { manage: true, read: true },
+ 'mock-index': { manage: true, read: true },
+ 'search-alias-2': { manage: true, read: true },
+ },
+ };
+
+ it('expands an alias with index data when no pattern passed', () => {
+ const expandedAliasList = expandAliases(mockIndexName, mockAliases, mockIndex, mockIndicesData);
+
+ expect(expandedAliasList).toEqual([
+ {
+ alias: true,
+ count: 100,
+ name: 'alias-1',
+ privileges: { manage: true, read: true },
+ ...mockIndex,
+ },
+ {
+ alias: true,
+ count: 100,
+ name: 'search-alias-2',
+ privileges: { manage: true, read: true },
+ ...mockIndex,
+ },
+ {
+ alias: true,
+ count: 0,
+ name: 'alias-with-missing-data',
+ privileges: { manage: true, read: true },
+ ...mockIndex,
+ },
+ ]);
+ });
+
+ it('expands only aliases that starts with alwaysShowSearchPattern', () => {
+ const expandedAliasList = expandAliases(
+ mockIndexName,
+ mockAliases,
+ mockIndex,
+ mockIndicesData,
+ 'search-'
+ );
+
+ expect(expandedAliasList).toEqual([
+ {
+ alias: true,
+ count: 100,
+ name: 'search-alias-2',
+ privileges: { manage: true, read: true },
+ ...mockIndex,
+ },
+ ]);
+ });
+});
diff --git a/x-pack/plugins/enterprise_search/server/lib/indices/utils/extract_always_show_indices.ts b/x-pack/plugins/enterprise_search/server/lib/indices/utils/extract_always_show_indices.ts
new file mode 100644
index 0000000000000..47103639b7866
--- /dev/null
+++ b/x-pack/plugins/enterprise_search/server/lib/indices/utils/extract_always_show_indices.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 { SecurityHasPrivilegesPrivileges } from '@elastic/elasticsearch/lib/api/typesWithBodyKey';
+
+import { ElasticsearchIndex } from '../../../../common/types/indices';
+
+export const getAlwaysShowAliases = (indexAndAliasNames: string[], alwaysShowNames: string[]) => {
+ if (alwaysShowNames.length === 0) return [];
+ // Only add the index and aliases that are not already included
+ return alwaysShowNames.filter((name) => !indexAndAliasNames.includes(name));
+};
+
+export const expandAliases = (
+ indexName: string,
+ aliases: string[],
+ index: Omit,
+ indicesData: {
+ indexCounts: Record;
+ indexPrivileges: Record;
+ },
+ alwaysShowSearchPattern?: 'search-'
+) => {
+ const filteredAliases = alwaysShowSearchPattern
+ ? aliases.filter((alias) => alias.startsWith(alwaysShowSearchPattern))
+ : aliases;
+ return filteredAliases.map((alias) => ({
+ alias: true,
+ count: indicesData.indexCounts[alias] ?? 0,
+ name: alias,
+ privileges: { manage: false, read: false, ...indicesData.indexPrivileges[indexName] },
+ ...index,
+ }));
+};
diff --git a/x-pack/plugins/enterprise_search/server/lib/indices/utils/get_index_data.test.ts b/x-pack/plugins/enterprise_search/server/lib/indices/utils/get_index_data.test.ts
new file mode 100644
index 0000000000000..7e9859a4e8076
--- /dev/null
+++ b/x-pack/plugins/enterprise_search/server/lib/indices/utils/get_index_data.test.ts
@@ -0,0 +1,250 @@
+/*
+ * 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 {
+ mockSingleIndexWithAliasesResponse,
+ mockMultiIndexResponse,
+} from '../../../__mocks__/fetch_indices.mock';
+
+import { IScopedClusterClient } from '@kbn/core/server';
+
+import { TotalIndexData } from '../fetch_indices';
+
+import { getIndexData, getIndexDataMapper } from './get_index_data';
+
+import * as mapIndexStatsModule from './map_index_stats';
+
+// While we are mocking a lot, there is no good way to check if this works not.
+// This tests only check if we call the 'get' api with correct parameters and
+// if we re-shape the response accordingly
+describe('getIndexData util function', () => {
+ beforeEach(() => {
+ jest.clearAllMocks();
+ });
+ const mockClient = {
+ asCurrentUser: { indices: { get: jest.fn() } },
+ };
+
+ it('returns index data with for non-hidden indices', async () => {
+ mockClient.asCurrentUser.indices.get.mockImplementationOnce(() => {
+ return mockSingleIndexWithAliasesResponse;
+ });
+
+ const indexData = await getIndexData(
+ mockClient as unknown as IScopedClusterClient,
+ '*',
+ ['open'],
+ false,
+ false
+ );
+
+ expect(mockClient.asCurrentUser.indices.get).toHaveBeenCalledWith({
+ expand_wildcards: ['open'],
+ features: ['aliases', 'settings'],
+ filter_path: ['*.aliases', '*.settings.index.hidden'],
+ index: '*',
+ });
+
+ expect(indexData).toEqual({
+ allIndexMatches: mockSingleIndexWithAliasesResponse,
+ alwaysShowMatchNames: [],
+ expandWildcards: ['open'],
+ indexAndAliasNames: ['search-regular-index'],
+ indicesNames: ['search-regular-index'],
+ });
+ });
+
+ it('returns index data and aliases for non-hidden indices', async () => {
+ mockClient.asCurrentUser.indices.get.mockImplementationOnce(() => {
+ return mockSingleIndexWithAliasesResponse;
+ });
+
+ const indexData = await getIndexData(
+ mockClient as unknown as IScopedClusterClient,
+ '*',
+ ['open'],
+ false,
+ true
+ );
+
+ expect(mockClient.asCurrentUser.indices.get).toHaveBeenCalledWith({
+ expand_wildcards: ['open'],
+ features: ['aliases', 'settings'],
+ filter_path: ['*.aliases', '*.settings.index.hidden'],
+ index: '*',
+ });
+
+ expect(indexData).toEqual({
+ allIndexMatches: mockSingleIndexWithAliasesResponse,
+ alwaysShowMatchNames: [],
+ expandWildcards: ['open'],
+ indexAndAliasNames: ['search-regular-index', 'search-alias-1', 'search-alias-2'],
+ indicesNames: ['search-regular-index'],
+ });
+ });
+
+ it('returns index data with hidden indices', async () => {
+ mockClient.asCurrentUser.indices.get.mockImplementationOnce(() => {
+ return mockMultiIndexResponse;
+ });
+
+ const indexData = await getIndexData(
+ mockClient as unknown as IScopedClusterClient,
+ '*',
+ ['hidden', 'all'],
+ true,
+ false
+ );
+
+ expect(mockClient.asCurrentUser.indices.get).toHaveBeenCalledWith({
+ expand_wildcards: ['hidden', 'all'],
+ features: ['aliases', 'settings'],
+ filter_path: ['*.aliases', '*.settings.index.hidden'],
+ index: '*',
+ });
+
+ expect(indexData).toEqual({
+ allIndexMatches: mockMultiIndexResponse,
+ alwaysShowMatchNames: [],
+ expandWildcards: ['hidden', 'all'],
+ indexAndAliasNames: [
+ 'hidden-index',
+ 'regular-index',
+ 'search-prefixed-hidden-index',
+ 'search-prefixed-regular-index',
+ ],
+ indicesNames: [
+ 'hidden-index',
+ 'regular-index',
+ 'search-prefixed-hidden-index',
+ 'search-prefixed-regular-index',
+ ],
+ });
+ });
+
+ it('returns index data and aliases with hidden indices', async () => {
+ mockClient.asCurrentUser.indices.get.mockImplementationOnce(() => {
+ return mockMultiIndexResponse;
+ });
+
+ const indexData = await getIndexData(
+ mockClient as unknown as IScopedClusterClient,
+ '*',
+ ['hidden', 'all'],
+ true,
+ true
+ );
+
+ expect(mockClient.asCurrentUser.indices.get).toHaveBeenCalledWith({
+ expand_wildcards: ['hidden', 'all'],
+ features: ['aliases', 'settings'],
+ filter_path: ['*.aliases', '*.settings.index.hidden'],
+ index: '*',
+ });
+
+ expect(indexData).toEqual({
+ allIndexMatches: mockMultiIndexResponse,
+ alwaysShowMatchNames: [],
+ expandWildcards: ['hidden', 'all'],
+
+ indexAndAliasNames: [
+ 'hidden-index',
+ 'alias-hidden-index',
+ 'search-alias-hidden-index',
+ 'regular-index',
+ 'alias-regular-index',
+ 'search-alias-regular-index',
+ 'search-prefixed-hidden-index',
+ 'alias-search-prefixed-hidden-index',
+ 'search-alias-search-prefixed-hidden-index',
+ 'search-prefixed-regular-index',
+ 'alias-search-prefixed-regular-index',
+ 'search-alias-search-prefixed-regular-index',
+ ],
+ indicesNames: [
+ 'hidden-index',
+ 'regular-index',
+ 'search-prefixed-hidden-index',
+ 'search-prefixed-regular-index',
+ ],
+ });
+ });
+
+ // This is a happy path tests for a case where we set all parameter on route
+ // There are other possible cases where if you set includeAliases to false and still
+ // pass a search- pattern. you will get some weird results back. It won't be false but
+ // useless. These will go away on the next iterations we have.
+ it('returns non-hidden and alwaysShowSearchPattern matching indices', async () => {
+ mockClient.asCurrentUser.indices.get.mockImplementationOnce(() => {
+ return mockMultiIndexResponse;
+ });
+
+ const indexData = await getIndexData(
+ mockClient as unknown as IScopedClusterClient,
+ '*',
+ ['hidden', 'all'],
+ false,
+ true,
+ 'search-'
+ );
+
+ expect(mockClient.asCurrentUser.indices.get).toHaveBeenCalledWith({
+ expand_wildcards: ['hidden', 'all'],
+ features: ['aliases', 'settings'],
+ filter_path: ['*.aliases', '*.settings.index.hidden'],
+ index: '*',
+ });
+
+ expect(indexData).toEqual({
+ allIndexMatches: mockMultiIndexResponse,
+ alwaysShowMatchNames: [
+ 'hidden-index',
+ 'regular-index',
+ 'search-prefixed-hidden-index',
+ 'search-prefixed-regular-index',
+ ],
+ expandWildcards: ['hidden', 'all'],
+ indexAndAliasNames: [
+ 'hidden-index',
+ 'alias-hidden-index',
+ 'search-alias-hidden-index',
+ 'regular-index',
+ 'alias-regular-index',
+ 'search-alias-regular-index',
+ 'search-prefixed-hidden-index',
+ 'alias-search-prefixed-hidden-index',
+ 'search-alias-search-prefixed-hidden-index',
+ 'search-prefixed-regular-index',
+ 'alias-search-prefixed-regular-index',
+ 'search-alias-search-prefixed-regular-index',
+ ],
+ indicesNames: ['regular-index', 'search-prefixed-regular-index'],
+ });
+ });
+});
+
+describe('getIndexDataMapper util function', () => {
+ it('returns a function that calls mapIndexStats with parameters set', () => {
+ jest.spyOn(mapIndexStatsModule, 'mapIndexStats');
+
+ const mockIndexData: TotalIndexData = {
+ allIndexMatches: { 'index-name': { aliases: {} } },
+ indexCounts: {},
+ indexPrivileges: {},
+ indicesStats: { 'index-name': {} },
+ };
+
+ const indexDataMapperFunction = getIndexDataMapper(mockIndexData);
+ expect(mapIndexStatsModule.mapIndexStats).not.toHaveBeenCalled();
+ indexDataMapperFunction('index-name');
+ expect(mapIndexStatsModule.mapIndexStats).toHaveBeenCalledWith(
+ { aliases: {} },
+ {},
+ 'index-name'
+ );
+ });
+});
diff --git a/x-pack/plugins/enterprise_search/server/lib/indices/utils/get_index_data.ts b/x-pack/plugins/enterprise_search/server/lib/indices/utils/get_index_data.ts
new file mode 100644
index 0000000000000..e3c667141e95d
--- /dev/null
+++ b/x-pack/plugins/enterprise_search/server/lib/indices/utils/get_index_data.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 { ExpandWildcard } from '@elastic/elasticsearch/lib/api/types';
+
+import { IScopedClusterClient } from '@kbn/core/server';
+
+import { TotalIndexData } from '../fetch_indices';
+
+import { mapIndexStats } from './map_index_stats';
+
+export const getIndexData = async (
+ client: IScopedClusterClient,
+ indexPattern: string,
+ expandWildcards: ExpandWildcard[],
+ returnHiddenIndices: boolean,
+ includeAliases: boolean,
+ alwaysShowSearchPattern?: 'search-'
+) => {
+ const totalIndices = await client.asCurrentUser.indices.get({
+ expand_wildcards: expandWildcards,
+ // for better performance only compute aliases and settings of indices but not mappings
+ features: ['aliases', 'settings'],
+ // only get specified index properties from ES to keep the response under 536MB
+ // node.js string length limit: https://github.com/nodejs/node/issues/33960
+ filter_path: ['*.aliases', '*.settings.index.hidden'],
+ index: indexPattern,
+ });
+
+ // Index names that with one of their aliases match with the alwaysShowSearchPattern
+ const alwaysShowPatternMatches = new Set();
+
+ const indexAndAliasNames: string[] = Object.keys(totalIndices).reduce(
+ (accum: string[], indexName: string) => {
+ accum.push(indexName);
+
+ if (includeAliases) {
+ const aliases = Object.keys(totalIndices[indexName].aliases!);
+ aliases.forEach((alias) => {
+ accum.push(alias);
+
+ // Add indexName to the set if an alias matches the pattern
+ if (alwaysShowSearchPattern && alias.startsWith(alwaysShowSearchPattern)) {
+ alwaysShowPatternMatches.add(indexName);
+ }
+ });
+ }
+ return accum;
+ },
+ []
+ );
+
+ const indicesNames = returnHiddenIndices
+ ? Object.keys(totalIndices)
+ : Object.keys(totalIndices).filter(
+ (indexName) => !(totalIndices[indexName]?.settings?.index?.hidden === 'true')
+ );
+ return {
+ allIndexMatches: totalIndices,
+ alwaysShowMatchNames: Array.from(alwaysShowPatternMatches),
+ expandWildcards,
+ indexAndAliasNames,
+ indicesNames,
+ };
+};
+
+export const getIndexDataMapper = (totalIndexData: TotalIndexData) => {
+ return (indexName: string) =>
+ mapIndexStats(
+ totalIndexData.allIndexMatches[indexName],
+ totalIndexData.indicesStats[indexName],
+ indexName
+ );
+};
diff --git a/x-pack/plugins/enterprise_search/server/lib/indices/utils/map_index_stats.test.ts b/x-pack/plugins/enterprise_search/server/lib/indices/utils/map_index_stats.test.ts
new file mode 100644
index 0000000000000..b084d454296a1
--- /dev/null
+++ b/x-pack/plugins/enterprise_search/server/lib/indices/utils/map_index_stats.test.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 {
+ mockSingleIndexResponse,
+ mockSingleIndexStatsResponse,
+} from '../../../__mocks__/fetch_indices.mock';
+
+import { IndicesStatsIndicesStats } from '@elastic/elasticsearch/lib/api/types';
+
+import { mapIndexStats } from './map_index_stats';
+
+describe('mapIndexStats util function', () => {
+ it('maps index data and index status to api expected shape', () => {
+ const mappedResult = mapIndexStats(
+ mockSingleIndexResponse['search-regular-index'],
+ mockSingleIndexStatsResponse.indices[
+ 'search-regular-index'
+ ] as unknown as IndicesStatsIndicesStats,
+ 'search-regular-index'
+ );
+
+ expect(mappedResult).toEqual({
+ aliases: [],
+ health: 'green',
+ hidden: false,
+ name: 'search-regular-index',
+ status: 'open',
+ total: {
+ docs: {
+ count: 100,
+ deleted: 0,
+ },
+ store: {
+ size_in_bytes: '105.47kb',
+ },
+ },
+ uuid: '83a81e7e-5955-4255-b008-5d6961203f57',
+ });
+ });
+});
diff --git a/x-pack/plugins/enterprise_search/server/lib/indices/utils/map_index_stats.ts b/x-pack/plugins/enterprise_search/server/lib/indices/utils/map_index_stats.ts
new file mode 100644
index 0000000000000..4ea47a67cf555
--- /dev/null
+++ b/x-pack/plugins/enterprise_search/server/lib/indices/utils/map_index_stats.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 { IndicesIndexState, IndicesStatsIndicesStats } from '@elastic/elasticsearch/lib/api/types';
+
+import { ByteSizeValue } from '@kbn/config-schema';
+
+import { ElasticsearchIndex } from '../../../../common/types/indices';
+
+export const mapIndexStats = (
+ indexData: IndicesIndexState,
+ indexStats: IndicesStatsIndicesStats,
+ indexName: string
+): Omit & { aliases: string[] } => {
+ const aliases = Object.keys(indexData.aliases!);
+ const sizeInBytes = new ByteSizeValue(indexStats?.total?.store?.size_in_bytes ?? 0).toString();
+
+ const docCount = indexStats?.total?.docs?.count ?? 0;
+ const docDeleted = indexStats?.total?.docs?.deleted ?? 0;
+ const total = {
+ docs: {
+ count: docCount,
+ deleted: docDeleted,
+ },
+ store: {
+ size_in_bytes: sizeInBytes,
+ },
+ };
+
+ return {
+ aliases,
+ health: indexStats?.health,
+ hidden: Boolean(indexData.settings?.index?.hidden),
+ name: indexName,
+ status: indexStats?.status,
+ total,
+ uuid: indexStats?.uuid,
+ };
+};
diff --git a/x-pack/plugins/enterprise_search/server/routes/enterprise_search/analytics.ts b/x-pack/plugins/enterprise_search/server/routes/enterprise_search/analytics.ts
index 0ac7deb24ec2d..d01740e384323 100644
--- a/x-pack/plugins/enterprise_search/server/routes/enterprise_search/analytics.ts
+++ b/x-pack/plugins/enterprise_search/server/routes/enterprise_search/analytics.ts
@@ -108,7 +108,20 @@ export function registerAnalyticsRoutes({ router, log }: RouteDependencies) {
response,
statusCode: 409,
});
+ } else if ((error as Error).message === ErrorCode.ANALYTICS_COLLECTION_NAME_INVALID) {
+ return createError({
+ errorCode: (error as Error).message as ErrorCode,
+ message: i18n.translate(
+ 'xpack.enterpriseSearch.server.routes.addAnalyticsCollection.analyticsCollectionNameInvalidError',
+ {
+ defaultMessage: 'Name must only contain alphanumeric characters and underscores',
+ }
+ ),
+ response,
+ statusCode: 400,
+ });
}
+
throw error;
}
})
diff --git a/x-pack/plugins/enterprise_search/server/routes/enterprise_search/connectors.ts b/x-pack/plugins/enterprise_search/server/routes/enterprise_search/connectors.ts
index e9ac4e96ba923..b17cbffd68c40 100644
--- a/x-pack/plugins/enterprise_search/server/routes/enterprise_search/connectors.ts
+++ b/x-pack/plugins/enterprise_search/server/routes/enterprise_search/connectors.ts
@@ -10,6 +10,7 @@ import { i18n } from '@kbn/i18n';
import { ErrorCode } from '../../../common/types/error_codes';
import { addConnector } from '../../lib/connectors/add_connector';
+import { fetchSyncJobsByConnectorId } from '../../lib/connectors/fetch_sync_jobs';
import { startConnectorSync } from '../../lib/connectors/start_sync';
import { updateConnectorConfiguration } from '../../lib/connectors/update_connector_configuration';
import { updateConnectorScheduling } from '../../lib/connectors/update_connector_scheduling';
@@ -111,4 +112,29 @@ export function registerConnectorRoutes({ router, log }: RouteDependencies) {
return response.ok();
})
);
+
+ router.get(
+ {
+ path: '/internal/enterprise_search/connectors/{connectorId}/sync_jobs',
+ validate: {
+ params: schema.object({
+ connectorId: schema.string(),
+ }),
+ query: schema.object({
+ page: schema.number({ defaultValue: 0, min: 0 }),
+ size: schema.number({ defaultValue: 10, min: 0 }),
+ }),
+ },
+ },
+ elasticsearchErrorHandler(log, async (context, request, response) => {
+ const { client } = (await context.core).elasticsearch;
+ const result = await fetchSyncJobsByConnectorId(
+ client,
+ request.params.connectorId,
+ request.query.page,
+ request.query.size
+ );
+ return response.ok({ body: result });
+ })
+ );
}
diff --git a/x-pack/plugins/enterprise_search/server/routes/enterprise_search/indices.ts b/x-pack/plugins/enterprise_search/server/routes/enterprise_search/indices.ts
index e481abea40a1a..183b7cb4b3438 100644
--- a/x-pack/plugins/enterprise_search/server/routes/enterprise_search/indices.ts
+++ b/x-pack/plugins/enterprise_search/server/routes/enterprise_search/indices.ts
@@ -15,7 +15,7 @@ import { deleteConnectorById } from '../../lib/connectors/delete_connector';
import { fetchConnectorByIndexName, fetchConnectors } from '../../lib/connectors/fetch_connectors';
import { fetchCrawlerByIndexName, fetchCrawlers } from '../../lib/crawler/fetch_crawlers';
-import { createApiIndex } from '../../lib/indices/create_index';
+import { createIndex } from '../../lib/indices/create_index';
import { fetchIndex } from '../../lib/indices/fetch_index';
import { fetchIndices } from '../../lib/indices/fetch_indices';
import { generateApiKey } from '../../lib/indices/generate_api_key';
@@ -319,7 +319,7 @@ export function registerIndexRoutes({ router, log }: RouteDependencies) {
});
}
- const createIndexResponse = await createApiIndex(client, indexName, language);
+ const createIndexResponse = await createIndex(client, indexName, language, true);
return response.ok({
body: createIndexResponse,
diff --git a/x-pack/plugins/files/public/files_client/files_client.ts b/x-pack/plugins/files/public/files_client/files_client.ts
index 2f01405ee1492..922846cde2aaf 100644
--- a/x-pack/plugins/files/public/files_client/files_client.ts
+++ b/x-pack/plugins/files/public/files_client/files_client.ts
@@ -8,7 +8,7 @@
import { pipe } from 'fp-ts/lib/function';
import * as qs from 'query-string';
import type { HttpStart } from '@kbn/core/public';
-import type { FilesClient } from '../types';
+import type { ScopedFilesClient, FilesClient } from '../types';
import {
API_BASE_PATH,
FILES_API_BASE_PATH,
@@ -65,47 +65,70 @@ export const apiRoutes = {
getMetricsRoute: () => `${API_BASE_PATH}/metrics`,
};
-interface Args {
- fileKind: string;
+/**
+ * Arguments to create a new {@link FileClient}.
+ */
+export interface Args {
+ /**
+ * The http start service from core.
+ */
http: HttpStart;
}
+/**
+ * Arguments to create a new {@link ScopedFilesClient}.
+ */
+export interface ScopedArgs extends Args {
+ /**
+ * The file kind to scope all requests to where file kinds are needed.
+ */
+ fileKind: string;
+}
+
const commonBodyHeaders = {
headers: {
'content-type': 'application/json',
},
};
-export const createFilesClient = ({ http, fileKind }: Args): FilesClient => {
+export function createFilesClient(args: Args): FilesClient;
+export function createFilesClient(scopedArgs: ScopedArgs): ScopedFilesClient;
+export function createFilesClient({
+ http,
+ fileKind: scopedFileKind,
+}: {
+ http: HttpStart;
+ fileKind?: string;
+}): FilesClient | ScopedFilesClient {
const api: FilesClient = {
- create: (args) => {
- return http.post(apiRoutes.getCreateFileRoute(fileKind), {
+ create: ({ kind, ...args }) => {
+ return http.post(apiRoutes.getCreateFileRoute(scopedFileKind ?? kind), {
headers: commonBodyHeaders,
body: JSON.stringify(args),
});
},
- delete: (args) => {
- return http.delete(apiRoutes.getDeleteRoute(fileKind, args.id));
+ delete: ({ kind, ...args }) => {
+ return http.delete(apiRoutes.getDeleteRoute(scopedFileKind ?? kind, args.id));
},
- download: (args) => {
- return http.get(apiRoutes.getDownloadRoute(fileKind, args.id, args.fileName), {
+ download: ({ kind, ...args }) => {
+ return http.get(apiRoutes.getDownloadRoute(scopedFileKind ?? kind, args.id, args.fileName), {
headers: { Accept: '*/*' },
});
},
- getById: (args) => {
- return http.get(apiRoutes.getByIdRoute(fileKind, args.id));
+ getById: ({ kind, ...args }) => {
+ return http.get(apiRoutes.getByIdRoute(scopedFileKind ?? kind, args.id));
},
- list(args = {}) {
- return http.get(apiRoutes.getListRoute(fileKind, args.page, args.perPage));
+ list({ kind, ...args } = { kind: '' }) {
+ return http.get(apiRoutes.getListRoute(scopedFileKind ?? kind, args.page, args.perPage));
},
- update: ({ id, ...body }) => {
- return http.patch(apiRoutes.getUpdateRoute(fileKind, id), {
+ update: ({ kind, id, ...body }) => {
+ return http.patch(apiRoutes.getUpdateRoute(scopedFileKind ?? kind, id), {
headers: commonBodyHeaders,
body: JSON.stringify(body),
});
},
- upload: (args) => {
- return http.put(apiRoutes.getUploadRoute(fileKind, args.id), {
+ upload: ({ kind, ...args }) => {
+ return http.put(apiRoutes.getUploadRoute(scopedFileKind ?? kind, args.id), {
headers: {
'Content-Type': 'application/octet-stream',
},
@@ -113,20 +136,25 @@ export const createFilesClient = ({ http, fileKind }: Args): FilesClient => {
body: args.body as BodyInit,
});
},
- share: ({ fileId, name, validUntil }) => {
- return http.post(apiRoutes.getShareRoute(fileKind, fileId), {
+ getDownloadHref: ({ fileKind: kind, id }) => {
+ return `${http.basePath.prepend(apiRoutes.getDownloadRoute(scopedFileKind ?? kind, id))}`;
+ },
+ share: ({ kind, fileId, name, validUntil }) => {
+ return http.post(apiRoutes.getShareRoute(scopedFileKind ?? kind, fileId), {
headers: commonBodyHeaders,
body: JSON.stringify({ name, validUntil }),
});
},
- unshare: ({ id }) => {
- return http.delete(apiRoutes.getShareRoute(fileKind, id));
+ unshare: ({ kind, id }) => {
+ return http.delete(apiRoutes.getShareRoute(scopedFileKind ?? kind, id));
},
- getShare: ({ id }) => {
- return http.get(apiRoutes.getShareRoute(fileKind, id));
+ getShare: ({ kind, id }) => {
+ return http.get(apiRoutes.getShareRoute(scopedFileKind ?? kind, id));
},
- listShares: ({ forFileId, page, perPage }) => {
- return http.get(apiRoutes.getListSharesRoute(fileKind, page, perPage, forFileId));
+ listShares: ({ kind, forFileId, page, perPage }) => {
+ return http.get(
+ apiRoutes.getListSharesRoute(scopedFileKind ?? kind, page, perPage, forFileId)
+ );
},
find: ({ page, perPage, ...filterArgs }) => {
return http.post(apiRoutes.getFindRoute(page, perPage), {
@@ -140,9 +168,6 @@ export const createFilesClient = ({ http, fileKind }: Args): FilesClient => {
publicDownload: ({ token, fileName }) => {
return http.get(apiRoutes.getPublicDownloadRoute(token, fileName));
},
- getDownloadHref: ({ id }) => {
- return `${http.basePath.prepend(apiRoutes.getDownloadRoute(fileKind, id))}`;
- },
};
return api;
-};
+}
diff --git a/x-pack/plugins/files/public/index.ts b/x-pack/plugins/files/public/index.ts
index 36a570c209683..0c8d9dd242b51 100644
--- a/x-pack/plugins/files/public/index.ts
+++ b/x-pack/plugins/files/public/index.ts
@@ -7,7 +7,12 @@
import { FilesPlugin } from './plugin';
export type { FilesSetup, FilesStart } from './plugin';
-export type { FilesClient, FilesClientFactory, FilesClientResponses } from './types';
+export type {
+ FilesClient,
+ ScopedFilesClient,
+ FilesClientFactory,
+ FilesClientResponses,
+} from './types';
export function plugin() {
return new FilesPlugin();
diff --git a/x-pack/plugins/files/public/plugin.ts b/x-pack/plugins/files/public/plugin.ts
index 92358d067d36a..22276ba377d8e 100644
--- a/x-pack/plugins/files/public/plugin.ts
+++ b/x-pack/plugins/files/public/plugin.ts
@@ -34,6 +34,9 @@ export class FilesPlugin implements Plugin {
asScoped(fileKind: string) {
return createFilesClient({ fileKind, http: core.http });
},
+ asUnscoped() {
+ return createFilesClient({ http: core.http });
+ },
},
};
return this.api;
diff --git a/x-pack/plugins/files/public/types.ts b/x-pack/plugins/files/public/types.ts
index 3a52b863bc7e4..8a2a67bea8e93 100644
--- a/x-pack/plugins/files/public/types.ts
+++ b/x-pack/plugins/files/public/types.ts
@@ -24,21 +24,43 @@ import type {
HttpApiInterfaceEntryDefinition,
} from '../common/api_routes';
+type UnscopedClientMethodFrom = (
+ args: E['inputs']['body'] & E['inputs']['params'] & E['inputs']['query']
+) => Promise;
+
/**
* @param args - Input to the endpoint which includes body, params and query of the RESTful endpoint.
*/
type ClientMethodFrom = (
- args: E['inputs']['body'] & E['inputs']['params'] & E['inputs']['query']
+ args: Parameters>[0] & { kind: string }
) => Promise;
-type ClientMethodOptionalArgsFrom = (
- args?: E['inputs']['body'] & E['inputs']['params'] & E['inputs']['query']
-) => Promise;
+interface GlobalEndpoints {
+ /**
+ * Get metrics of file system, like storage usage.
+ *
+ * @param args - Get metrics arguments
+ */
+ getMetrics: () => Promise;
+ /**
+ * Download a file, bypassing regular security by way of a
+ * secret share token.
+ *
+ * @param args - Get public download arguments.
+ */
+ publicDownload: UnscopedClientMethodFrom;
+ /**
+ * Find a set of files given some filters.
+ *
+ * @param args - File filters
+ */
+ find: UnscopedClientMethodFrom;
+}
/**
* A client that can be used to manage a specific {@link FileKind}.
*/
-export interface FilesClient {
+export interface FilesClient extends GlobalEndpoints {
/**
* Create a new file object with the provided metadata.
*
@@ -62,13 +84,7 @@ export interface FilesClient {
*
* @param args - list files args
*/
- list: ClientMethodOptionalArgsFrom;
- /**
- * Find a set of files given some filters.
- *
- * @param args - File filters
- */
- find: ClientMethodFrom;
+ list: ClientMethodFrom;
/**
* Update a set of of metadata values of the file object.
*
@@ -87,6 +103,11 @@ export interface FilesClient {
* @param args - download file args
*/
download: ClientMethodFrom;
+ /**
+ * Get a string for downloading a file that can be passed to a button element's
+ * href for download.
+ */
+ getDownloadHref: (file: FileJSON) => string;
/**
* Share a file by creating a new file share instance.
*
@@ -115,25 +136,6 @@ export interface FilesClient {
* @param args - Get file share arguments
*/
listShares: ClientMethodFrom;
- /**
- * Get metrics of file system, like storage usage.
- *
- * @param args - Get metrics arguments
- */
- getMetrics: ClientMethodFrom;
- /**
- * Download a file, bypassing regular security by way of a
- * secret share token.
- *
- * @param args - Get public download arguments.
- */
- publicDownload: ClientMethodFrom;
-
- /**
- * Get a string for downloading a file that can be passed to a button element's
- * href for download.
- */
- getDownloadHref: (file: FileJSON) => string;
}
export type FilesClientResponses = {
@@ -141,13 +143,29 @@ export type FilesClientResponses = {
};
/**
- * A factory for creating a {@link FilesClient}
+ * A files client that is scoped to a specific {@link FileKind}.
+ *
+ * More convenient if you want to re-use the same client for the same file kind
+ * and not specify the kind every time.
+ */
+export type ScopedFilesClient = {
+ [K in keyof FilesClient]: K extends 'list'
+ ? (arg?: Omit[0], 'kind'>) => ReturnType
+ : (arg: Omit[0], 'kind'>) => ReturnType;
+};
+
+/**
+ * A factory for creating a {@link ScopedFilesClient}
*/
export interface FilesClientFactory {
/**
- * Create a {@link FileClient} for a given {@link FileKind}.
+ * Create a files client.
+ */
+ asUnscoped(): FilesClient;
+ /**
+ * Create a {@link ScopedFileClient} for a given {@link FileKind}.
*
* @param fileKind - The {@link FileKind} to create a client for.
*/
- asScoped(fileKind: string): FilesClient;
+ asScoped(fileKind: string): ScopedFilesClient;
}
diff --git a/x-pack/plugins/fleet/cypress/integration/a11y/home_page.spec.ts b/x-pack/plugins/fleet/cypress/integration/a11y/home_page.spec.ts
index f923187c93653..b5d6e9d605f1e 100644
--- a/x-pack/plugins/fleet/cypress/integration/a11y/home_page.spec.ts
+++ b/x-pack/plugins/fleet/cypress/integration/a11y/home_page.spec.ts
@@ -9,50 +9,50 @@ import 'cypress-real-events/support';
import { checkA11y } from '../../support/commands';
import { FLEET, navigateTo } from '../../tasks/navigation';
import {
+ AGENT_FLYOUT,
GENERATE_FLEET_SERVER_POLICY_BUTTON,
- AGENTS_QUICK_START_TAB_BUTTON,
PLATFORM_TYPE_LINUX_BUTTON,
- AGENTS_ADVANCED_TAB_BUTTON,
ADVANCED_FLEET_SERVER_ADD_HOST_BUTTON,
ADVANCED_FLEET_SERVER_GENERATE_SERVICE_TOKEN_BUTTON,
AGENT_POLICIES_TAB,
- AGENT_POLICIES_CREATE_AGENT_POLICY_BUTTON,
- AGENT_POLICIES_CREATE_AGENT_POLICY_FLYOUT_TITLE,
+ AGENT_POLICIES_CREATE_AGENT_POLICY_FLYOUT,
AGENT_POLICY_CREATE_AGENT_POLICY_NAME_FIELD,
AGENT_POLICIES_FLYOUT_ADVANCED_DEFAULT_NAMESPACE_HEADER,
AGENT_POLICY_FLYOUT_CREATE_BUTTON,
ENROLLMENT_TOKENS_TAB,
- ENROLLMENT_TOKENS_CREATE_TOKEN_BUTTON,
- ENROLLMENT_TOKENS_CREATE_TOKEN_NAME_FIELD,
+ ENROLLMENT_TOKENS,
DATA_STREAMS_TAB,
SETTINGS_TAB,
SETTINGS_FLEET_SERVER_HOST_HEADING,
+ FLEET_SERVER_HOST_INPUT,
} from '../../screens/fleet';
import { AGENT_POLICY_NAME_LINK } from '../../screens/integrations';
import { cleanupAgentPolicies, unenrollAgent } from '../../tasks/cleanup';
describe('Home page', () => {
before(() => {
navigateTo(FLEET);
- cy.getBySel(AGENTS_QUICK_START_TAB_BUTTON, { timeout: 15000 }).should('be.visible');
+ cy.getBySel(AGENT_FLYOUT.QUICK_START_TAB_BUTTON, { timeout: 15000 }).should('be.visible');
});
describe('Agents', () => {
const fleetServerHost = 'https://localhost:8220';
+
describe('Quick Start', () => {
it('Get started with fleet', () => {
checkA11y({ skipFailures: false });
});
it('Install Fleet Server', () => {
- cy.getBySel('fleetServerHostInput', { timeout: 15000 }).should('be.visible');
- cy.getBySel('fleetServerHostInput').getBySel('comboBoxSearchInput').type(fleetServerHost);
+ cy.getBySel(FLEET_SERVER_HOST_INPUT, { timeout: 15000 }).should('be.visible');
+ cy.getBySel(FLEET_SERVER_HOST_INPUT).getBySel('comboBoxSearchInput').type(fleetServerHost);
cy.getBySel(GENERATE_FLEET_SERVER_POLICY_BUTTON).click();
cy.getBySel(PLATFORM_TYPE_LINUX_BUTTON, { timeout: 15000 }).should('be.visible');
checkA11y({ skipFailures: false });
});
});
+
describe('Advanced', () => {
before(() => {
- cy.getBySel(AGENTS_ADVANCED_TAB_BUTTON).click();
+ cy.getBySel(AGENT_FLYOUT.ADVANCED_TAB_BUTTON).click();
});
it('Select policy for fleet', () => {
checkA11y({ skipFailures: false });
@@ -69,19 +69,20 @@ describe('Home page', () => {
});
});
});
+
describe('Agent Policies', () => {
before(() => {
cy.getBySel(AGENT_POLICIES_TAB).click();
- cy.getBySel(AGENT_POLICIES_CREATE_AGENT_POLICY_BUTTON, { timeout: 15000 }).should(
- 'be.visible'
- );
+ cy.getBySel(AGENT_POLICIES_CREATE_AGENT_POLICY_FLYOUT.CREATE_BUTTON, {
+ timeout: 15000,
+ }).should('be.visible');
});
it('Agent Table', () => {
checkA11y({ skipFailures: false });
});
it('Create Policy Flyout', () => {
- cy.getBySel(AGENT_POLICIES_CREATE_AGENT_POLICY_BUTTON).click();
- cy.getBySel(AGENT_POLICIES_CREATE_AGENT_POLICY_FLYOUT_TITLE, { timeout: 15000 }).should(
+ cy.getBySel(AGENT_POLICIES_CREATE_AGENT_POLICY_FLYOUT.CREATE_BUTTON).click();
+ cy.getBySel(AGENT_POLICIES_CREATE_AGENT_POLICY_FLYOUT.TITLE, { timeout: 15000 }).should(
'be.visible'
);
cy.getBySel(AGENT_POLICY_CREATE_AGENT_POLICY_NAME_FIELD).type('testName');
@@ -97,6 +98,7 @@ describe('Home page', () => {
checkA11y({ skipFailures: true });
});
});
+
describe('Enrollment Tokens', () => {
before(() => {
cy.getBySel(ENROLLMENT_TOKENS_TAB).click();
@@ -106,13 +108,14 @@ describe('Home page', () => {
checkA11y({ skipFailures: false });
});
it('Create Enrollment Token Modal', () => {
- cy.getBySel(ENROLLMENT_TOKENS_CREATE_TOKEN_BUTTON).click();
- cy.getBySel(ENROLLMENT_TOKENS_CREATE_TOKEN_NAME_FIELD, { timeout: 15000 }).should(
+ cy.getBySel(ENROLLMENT_TOKENS.CREATE_TOKEN_BUTTON).click();
+ cy.getBySel(ENROLLMENT_TOKENS.CREATE_TOKEN_MODAL_NAME_FIELD, { timeout: 15000 }).should(
'be.visible'
);
checkA11y({ skipFailures: false });
});
});
+
describe('Data Streams', () => {
before(() => {
cy.getBySel('confirmModalCancelButton').click();
diff --git a/x-pack/plugins/fleet/cypress/integration/agent_binary_download_source.spec.ts b/x-pack/plugins/fleet/cypress/integration/agent_binary_download_source.spec.ts
index c695939248826..095a87a28e130 100644
--- a/x-pack/plugins/fleet/cypress/integration/agent_binary_download_source.spec.ts
+++ b/x-pack/plugins/fleet/cypress/integration/agent_binary_download_source.spec.ts
@@ -10,10 +10,10 @@ import {
AGENT_BINARY_SOURCES_TABLE_ACTIONS,
AGENT_BINARY_SOURCES_FLYOUT,
AGENT_POLICY_FORM,
- CONFIRM_MODAL_CONFIRM_BUTTON,
} from '../screens/fleet';
import { cleanupDownloadSources } from '../tasks/cleanup';
import { FLEET, navigateTo } from '../tasks/navigation';
+import { CONFIRM_MODAL } from '../screens/navigation';
describe('Agent binary download source section', () => {
beforeEach(() => {
@@ -35,7 +35,7 @@ describe('Agent binary download source section', () => {
.clear()
.type('https://edited-default-host.co');
cy.getBySel(AGENT_BINARY_SOURCES_FLYOUT.SUBMIT_BUTTON).click();
- cy.getBySel(CONFIRM_MODAL_CONFIRM_BUTTON).click();
+ cy.getBySel(CONFIRM_MODAL.CONFIRM_BUTTON).click();
cy.intercept('api/fleet/agent_download_sources/fleet-default-download-source', {
host: 'https://edited-default-host.co',
diff --git a/x-pack/plugins/fleet/cypress/integration/agent.spec.ts b/x-pack/plugins/fleet/cypress/integration/agent_list.spec.ts
similarity index 54%
rename from x-pack/plugins/fleet/cypress/integration/agent.spec.ts
rename to x-pack/plugins/fleet/cypress/integration/agent_list.spec.ts
index 084ba548ff6c6..bc3cf5c2f6ed3 100644
--- a/x-pack/plugins/fleet/cypress/integration/agent.spec.ts
+++ b/x-pack/plugins/fleet/cypress/integration/agent_list.spec.ts
@@ -5,7 +5,11 @@
* 2.0.
*/
+import { FLEET_AGENT_LIST_PAGE } from '../screens/fleet';
+
import { createAgentDoc } from '../tasks/agents';
+import { setupFleetServer } from '../tasks/fleet_server';
+import { deleteFleetServerDocs, deleteAgentDocs } from '../tasks/cleanup';
const createAgentDocs = (kibanaVersion: string) => [
createAgentDoc('agent-1', 'policy-1'), // this agent will have upgrade available
@@ -14,29 +18,39 @@ const createAgentDocs = (kibanaVersion: string) => [
];
let docs: any[] = [];
-// TODO: create fleet server, fix version of agent to upgrade to an allowed version (>= fleet server's, < kibana)
-// https://github.com/elastic/kibana/issues/138121
-describe.skip('View agents', () => {
+
+describe('View agents list', () => {
before(() => {
- cy.task('deleteDocsByQuery', {
- index: '.fleet-agents',
- query: { match_all: {} },
- ignoreUnavailable: true,
- });
+ deleteFleetServerDocs(true);
+ deleteAgentDocs(true);
+ setupFleetServer();
+
cy.getKibanaVersion().then((version) => {
docs = createAgentDocs(version);
cy.task('insertDocs', { index: '.fleet-agents', docs });
});
});
after(() => {
- cy.task('deleteDocsByQuery', {
- index: '.fleet-agents',
- query: { match_all: {} },
- });
+ deleteFleetServerDocs();
+ deleteAgentDocs();
});
beforeEach(() => {
- cy.intercept('/api/fleet/agents/setup', { isReady: true });
+ cy.intercept('/api/fleet/agents/setup', {
+ isReady: true,
+ missing_optional_features: [],
+ missing_requirements: [],
+ });
cy.intercept('/api/fleet/setup', { isInitialized: true, nonFatalErrors: [] });
+ cy.intercept('/api/fleet/agents_status', {
+ total: 18,
+ inactive: 0,
+ online: 18,
+ error: 0,
+ offline: 0,
+ updating: 0,
+ other: 0,
+ events: 0,
+ });
cy.intercept(/\/api\/fleet\/agent_policies(\?.*)?$/, {
items: [
{
@@ -78,10 +92,10 @@ describe.skip('View agents', () => {
describe('Agent filter suggestions', () => {
it('should filter based on agent id', () => {
cy.visit('/app/fleet/agents');
- cy.getBySel('agentList.queryInput').type('agent.id: "agent-1"{enter}');
- cy.getBySel('fleetAgentListTable');
- cy.getBySel('fleetAgentListTable').find('tr').should('have.length', 2);
- cy.getBySel('fleetAgentListTable').contains('agent-1');
+ cy.getBySel(FLEET_AGENT_LIST_PAGE.QUERY_INPUT).type('agent.id: "agent-1"{enter}');
+ cy.getBySel(FLEET_AGENT_LIST_PAGE.TABLE);
+ cy.getBySel(FLEET_AGENT_LIST_PAGE.TABLE).find('tr').should('have.length', 2);
+ cy.getBySel(FLEET_AGENT_LIST_PAGE.TABLE).contains('agent-1');
});
});
@@ -89,19 +103,19 @@ describe.skip('View agents', () => {
it('should only show agents with upgrade available after click', () => {
cy.visit('/app/fleet/agents');
- cy.getBySel('agentList.showUpgradeable').click();
- cy.getBySel('fleetAgentListTable').find('tr').should('have.length', 17);
- cy.getBySel('fleetAgentListTable').contains('agent-1');
+ cy.getBySel(FLEET_AGENT_LIST_PAGE.SHOW_UPGRADEABLE).click();
+ cy.getBySel(FLEET_AGENT_LIST_PAGE.TABLE).find('tr').should('have.length', 17);
+ cy.getBySel(FLEET_AGENT_LIST_PAGE.TABLE).contains('agent-1');
});
it('should clear filter on second click', () => {
cy.visit('/app/fleet/agents');
- cy.getBySel('agentList.showUpgradeable').click();
- cy.getBySel('agentList.showUpgradeable').click();
- cy.getBySel('fleetAgentListTable').find('tr').should('have.length', 18);
- cy.getBySel('fleetAgentListTable').contains('agent-1');
- cy.getBySel('fleetAgentListTable').contains('agent-2');
+ cy.getBySel(FLEET_AGENT_LIST_PAGE.SHOW_UPGRADEABLE).click();
+ cy.getBySel(FLEET_AGENT_LIST_PAGE.SHOW_UPGRADEABLE).click();
+ cy.getBySel(FLEET_AGENT_LIST_PAGE.TABLE).find('tr').should('have.length', 19);
+ cy.getBySel(FLEET_AGENT_LIST_PAGE.TABLE).contains('agent-1');
+ cy.getBySel(FLEET_AGENT_LIST_PAGE.TABLE).contains('agent-2');
});
});
@@ -109,85 +123,92 @@ describe.skip('View agents', () => {
it('should should show all policies as options', () => {
cy.visit('/app/fleet/agents');
- cy.getBySel('agentList.policyFilter').click();
+ cy.getBySel(FLEET_AGENT_LIST_PAGE.POLICY_FILTER).click();
cy.get('button').contains('Agent policy 1');
cy.get('button').contains('Agent policy 2');
cy.get('button').contains('Agent policy 3');
});
+
it('should filter on single policy (no results)', () => {
cy.visit('/app/fleet/agents');
- cy.getBySel('agentList.policyFilter').click();
+ cy.getBySel(FLEET_AGENT_LIST_PAGE.POLICY_FILTER).click();
cy.get('button').contains('Agent policy 4').click();
- cy.getBySel('fleetAgentListTable').contains('No agents found');
+ cy.getBySel(FLEET_AGENT_LIST_PAGE.TABLE).contains('No agents found');
});
+
it('should filter on single policy', () => {
cy.visit('/app/fleet/agents');
- cy.getBySel('agentList.policyFilter').click();
+ cy.getBySel(FLEET_AGENT_LIST_PAGE.POLICY_FILTER).click();
cy.get('button').contains('Agent policy 1').click();
- cy.getBySel('fleetAgentListTable').find('tr').should('have.length', 2);
- cy.getBySel('fleetAgentListTable').contains('agent-1');
+ cy.getBySel(FLEET_AGENT_LIST_PAGE.TABLE).find('tr').should('have.length', 2);
+ cy.getBySel(FLEET_AGENT_LIST_PAGE.TABLE).contains('agent-1');
});
+
it('should filter on multiple policies', () => {
cy.visit('/app/fleet/agents');
- cy.getBySel('agentList.policyFilter').click();
+ cy.getBySel(FLEET_AGENT_LIST_PAGE.POLICY_FILTER).click();
cy.get('button').contains('Agent policy 1').click();
cy.get('button').contains('Agent policy 2').click();
- cy.getBySel('fleetAgentListTable').find('tr').should('have.length', 3);
- cy.getBySel('fleetAgentListTable').contains('agent-1');
- cy.getBySel('fleetAgentListTable').contains('agent-2');
+ cy.getBySel(FLEET_AGENT_LIST_PAGE.TABLE).find('tr').should('have.length', 3);
+ cy.getBySel(FLEET_AGENT_LIST_PAGE.TABLE).contains('agent-1');
+ cy.getBySel(FLEET_AGENT_LIST_PAGE.TABLE).contains('agent-2');
});
});
+
describe('Agent status filter', () => {
it('should filter on healthy (16 result)', () => {
cy.visit('/app/fleet/agents');
- cy.getBySel('agentList.statusFilter').click();
+ cy.getBySel(FLEET_AGENT_LIST_PAGE.STATUS_FILTER).click();
cy.get('button').contains('Healthy').click();
- cy.getBySel('fleetAgentListTable').find('tr').should('have.length', 17);
- cy.getBySel('fleetAgentListTable').contains('agent-1');
+ cy.getBySel(FLEET_AGENT_LIST_PAGE.TABLE).find('tr').should('have.length', 18);
+ cy.getBySel(FLEET_AGENT_LIST_PAGE.TABLE).contains('agent-1');
});
+
it('should filter on unhealthy (1 result)', () => {
cy.visit('/app/fleet/agents');
- cy.getBySel('agentList.statusFilter').click();
+ cy.getBySel(FLEET_AGENT_LIST_PAGE.STATUS_FILTER).click();
cy.get('button').contains('Unhealthy').click();
- cy.getBySel('fleetAgentListTable').find('tr').should('have.length', 2);
- cy.getBySel('fleetAgentListTable').contains('agent-2');
+ cy.getBySel(FLEET_AGENT_LIST_PAGE.TABLE).find('tr').should('have.length', 2);
+ cy.getBySel(FLEET_AGENT_LIST_PAGE.TABLE).contains('agent-2');
});
+
it('should filter on inactive (0 result)', () => {
cy.visit('/app/fleet/agents');
- cy.getBySel('agentList.statusFilter').click();
+ cy.getBySel(FLEET_AGENT_LIST_PAGE.STATUS_FILTER).click();
cy.get('button').contains('Inactive').click();
- cy.getBySel('fleetAgentListTable').contains('No agents found');
+ cy.getBySel(FLEET_AGENT_LIST_PAGE.TABLE).contains('No agents found');
});
+
it('should filter on healthy and unhealthy', () => {
cy.visit('/app/fleet/agents');
- cy.getBySel('agentList.statusFilter').click();
+ cy.getBySel(FLEET_AGENT_LIST_PAGE.STATUS_FILTER).click();
cy.get('button').contains('healthy').click();
cy.get('button').contains('Unhealthy').click();
- cy.getBySel('fleetAgentListTable').find('tr').should('have.length', 18);
- cy.getBySel('fleetAgentListTable').contains('agent-1');
- cy.getBySel('fleetAgentListTable').contains('agent-2');
+ cy.getBySel(FLEET_AGENT_LIST_PAGE.TABLE).find('tr').should('have.length', 19);
+ cy.getBySel(FLEET_AGENT_LIST_PAGE.TABLE).contains('agent-1');
+ cy.getBySel(FLEET_AGENT_LIST_PAGE.TABLE).contains('agent-2');
});
});
@@ -195,19 +216,19 @@ describe.skip('View agents', () => {
it('should allow to bulk upgrade agents', () => {
cy.visit('/app/fleet/agents');
- cy.getBySel('agentList.policyFilter').click();
+ cy.getBySel(FLEET_AGENT_LIST_PAGE.POLICY_FILTER).click();
cy.get('button').contains('Agent policy 3').click();
- cy.getBySel('fleetAgentListTable').find('tr').should('have.length', 16);
+ cy.getBySel(FLEET_AGENT_LIST_PAGE.TABLE).find('tr').should('have.length', 16);
- cy.getBySel('checkboxSelectAll').click();
+ cy.getBySel(FLEET_AGENT_LIST_PAGE.CHECKBOX_SELECT_ALL).click();
// Trigger a bulk upgrade
- cy.getBySel('agentBulkActionsButton').click();
+ cy.getBySel(FLEET_AGENT_LIST_PAGE.BULK_ACTIONS_BUTTON).click();
cy.get('button').contains('Upgrade 15 agents').click();
cy.get('.euiModalFooter button').contains('Upgrade 15 agents').click();
- // Cancel upgrade
- cy.getBySel('abortUpgradeBtn').click();
- cy.get('button').contains('Confirm').click();
+ // Cancel upgrade - this assertion is currently flaky
+ // cy.getBySel(CURRENT_BULK_UPGRADES_CALLOUT.ABORT_BTN).click();
+ // cy.get('button').contains('Confirm').click();
});
});
});
diff --git a/x-pack/plugins/fleet/cypress/integration/agent_policy.spec.ts b/x-pack/plugins/fleet/cypress/integration/agent_policy.spec.ts
index 694cf6c1527ae..63da2cbbfa389 100644
--- a/x-pack/plugins/fleet/cypress/integration/agent_policy.spec.ts
+++ b/x-pack/plugins/fleet/cypress/integration/agent_policy.spec.ts
@@ -4,6 +4,7 @@
* 2.0; you may not use this file except in compliance with the Elastic License
* 2.0.
*/
+import { TOAST_CLOSE_BTN } from '../screens/navigation';
describe('Edit agent policy', () => {
beforeEach(() => {
@@ -33,7 +34,7 @@ describe('Edit agent policy', () => {
it('should edit agent policy', () => {
cy.visit('/app/fleet/policies/policy-1/settings');
- cy.getBySel('toastCloseButton').click();
+ cy.getBySel(TOAST_CLOSE_BTN).click();
cy.get('[placeholder="Optional description"').clear().type('desc');
cy.intercept('/api/fleet/agent_policies/policy-1', {
diff --git a/x-pack/plugins/fleet/cypress/integration/enrollment_token.spec.ts b/x-pack/plugins/fleet/cypress/integration/enrollment_token.spec.ts
new file mode 100644
index 0000000000000..e60842a299267
--- /dev/null
+++ b/x-pack/plugins/fleet/cypress/integration/enrollment_token.spec.ts
@@ -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 { FLEET, navigateTo } from '../tasks/navigation';
+import { cleanupAgentPolicies } from '../tasks/cleanup';
+import { ENROLLMENT_TOKENS_TAB, ENROLLMENT_TOKENS } from '../screens/fleet';
+
+describe('Enrollment token page', () => {
+ before(() => {
+ navigateTo(FLEET);
+ cy.request({
+ method: 'POST',
+ url: '/api/fleet/agent_policies',
+ body: {
+ name: 'Agent policy 1',
+ namespace: 'default',
+ description: '',
+ monitoring_enabled: ['logs', 'metrics'],
+ id: 'agent-policy-1',
+ },
+ headers: { 'kbn-xsrf': 'cypress' },
+ });
+ cy.getBySel(ENROLLMENT_TOKENS_TAB).click();
+ });
+
+ after(() => {
+ cleanupAgentPolicies();
+ });
+
+ it('Create new Token', () => {
+ cy.getBySel(ENROLLMENT_TOKENS.CREATE_TOKEN_BUTTON).click();
+ cy.getBySel(ENROLLMENT_TOKENS.CREATE_TOKEN_MODAL_NAME_FIELD).clear().type('New Token');
+ cy.getBySel(ENROLLMENT_TOKENS.CREATE_TOKEN_MODAL_SELECT_FIELD).contains('Agent policy 1');
+ cy.get('.euiButton').contains('Create enrollment token').click({ force: true });
+
+ cy.getBySel(ENROLLMENT_TOKENS.LIST_TABLE, { timeout: 15000 }).contains('Agent policy 1');
+ });
+
+ it('Delete Token - inactivates the token', () => {
+ cy.visit('app/fleet/enrollment-tokens');
+ cy.getBySel(ENROLLMENT_TOKENS.LIST_TABLE).find('tr').should('have.length', 2);
+ cy.getBySel(ENROLLMENT_TOKENS.TABLE_REVOKE_BTN).first().click();
+ cy.get('.euiPanel').contains('Are you sure you want to revoke');
+ cy.get('.euiButton').contains('Revoke enrollment token').click({ force: true });
+
+ cy.getBySel(ENROLLMENT_TOKENS.TABLE_REVOKE_BTN).first().should('not.exist');
+ });
+});
diff --git a/x-pack/plugins/fleet/cypress/integration/fleet_agent_flyout.spec.ts b/x-pack/plugins/fleet/cypress/integration/fleet_agent_flyout.spec.ts
index 626fa1427f8f1..b907fb8ef4c79 100644
--- a/x-pack/plugins/fleet/cypress/integration/fleet_agent_flyout.spec.ts
+++ b/x-pack/plugins/fleet/cypress/integration/fleet_agent_flyout.spec.ts
@@ -5,25 +5,17 @@
* 2.0.
*/
-import { ADD_AGENT_BUTTON, ADD_AGENT_FLYOUT } from '../screens/fleet';
-import { cleanupAgentPolicies } from '../tasks/cleanup';
+import { ADD_AGENT_BUTTON, AGENT_FLYOUT } from '../screens/fleet';
+import { cleanupAgentPolicies, deleteFleetServerDocs, deleteAgentDocs } from '../tasks/cleanup';
import { createAgentDoc } from '../tasks/agents';
-import { setFleetServerHost } from '../tasks/fleet';
+import { setFleetServerHost } from '../tasks/fleet_server';
import { FLEET, navigateTo } from '../tasks/navigation';
const FLEET_SERVER_POLICY_ID = 'fleet-server-policy';
function cleanUp() {
- cy.task('deleteDocsByQuery', {
- index: '.fleet-agents',
- query: { match_all: {} },
- ignoreUnavailable: true,
- });
- cy.task('deleteDocsByQuery', {
- index: '.fleet-servers',
- query: { match_all: {} },
- ignoreUnavailable: true,
- });
+ deleteFleetServerDocs(true);
+ deleteAgentDocs(true);
cleanupAgentPolicies();
}
let kibanaVersion: string;
@@ -80,7 +72,7 @@ describe('Fleet add agent flyout', () => {
cy.getBySel(ADD_AGENT_BUTTON).click();
cy.intercept('POST', '/api/fleet/agent_policies?sys_monitoring=true').as('createAgentPolicy');
- cy.getBySel('createPolicyBtn').click();
+ cy.getBySel(AGENT_FLYOUT.CREATE_POLICY_BUTTON).click();
let agentPolicyId: string;
const startTime = Date.now();
@@ -89,7 +81,7 @@ describe('Fleet add agent flyout', () => {
agentPolicyId = xhr.response.body.item.id;
});
// verify create button changed to dropdown
- cy.getBySel('agentPolicyDropdown');
+ cy.getBySel(AGENT_FLYOUT.POLICY_DROPDOWN);
cy.wrap(null).then(() => {
cy.task('insertDoc', {
@@ -99,7 +91,7 @@ describe('Fleet add agent flyout', () => {
});
});
- cy.getBySel(ADD_AGENT_FLYOUT.CONFIRM_AGENT_ENROLLMENT_BUTTON);
+ cy.getBySel(AGENT_FLYOUT.CONFIRM_AGENT_ENROLLMENT_BUTTON);
cy.wrap(null).then(() => {
cy.task('insertDoc', {
@@ -113,7 +105,7 @@ describe('Fleet add agent flyout', () => {
});
});
- cy.getBySel(ADD_AGENT_FLYOUT.INCOMING_DATA_CONFIRMED_CALL_OUT);
+ cy.getBySel(AGENT_FLYOUT.INCOMING_DATA_CONFIRMED_CALL_OUT);
});
});
});
diff --git a/x-pack/plugins/fleet/cypress/integration/fleet_settings.spec.ts b/x-pack/plugins/fleet/cypress/integration/fleet_settings.spec.ts
index 338030e91f3da..a1c4eef06bdb5 100644
--- a/x-pack/plugins/fleet/cypress/integration/fleet_settings.spec.ts
+++ b/x-pack/plugins/fleet/cypress/integration/fleet_settings.spec.ts
@@ -5,7 +5,8 @@
* 2.0.
*/
-import { CONFIRM_MODAL_BTN } from '../screens/integrations';
+import { TOAST_CLOSE_BTN, CONFIRM_MODAL } from '../screens/navigation';
+import { SETTINGS_SAVE_BTN, SETTINGS_OUTPUTS } from '../screens/fleet';
describe('Edit settings', () => {
beforeEach(() => {
@@ -25,11 +26,11 @@ describe('Edit settings', () => {
});
cy.visit('/app/fleet/settings');
- cy.getBySel('toastCloseButton').click();
+ cy.getBySel(TOAST_CLOSE_BTN).click();
});
it('should update Fleet server hosts', () => {
- cy.getBySel('editHostsBtn').click();
+ cy.getBySel(SETTINGS_OUTPUTS.EDIT_HOSTS_BTN).click();
cy.get('[placeholder="Specify host URL"').type('https://localhost:8220');
cy.intercept('/api/fleet/settings', {
@@ -39,8 +40,8 @@ describe('Edit settings', () => {
fleet_server_hosts: ['https://localhost:8220'],
}).as('updateSettings');
- cy.getBySel('saveApplySettingsBtn').click();
- cy.getBySel(CONFIRM_MODAL_BTN).click();
+ cy.getBySel(SETTINGS_SAVE_BTN).click();
+ cy.getBySel(CONFIRM_MODAL.CONFIRM_BUTTON).click();
cy.wait('@updateSettings').then((interception) => {
expect(interception.request.body.fleet_server_hosts[0]).to.equal('https://localhost:8220');
@@ -48,8 +49,8 @@ describe('Edit settings', () => {
});
it('should update outputs', () => {
- cy.getBySel('editOutputBtn').click();
- cy.get('[placeholder="Specify name"').clear().type('output-1');
+ cy.getBySel(SETTINGS_OUTPUTS.EDIT_BTN).click();
+ cy.getBySel(SETTINGS_OUTPUTS.NAME_INPUT).clear().type('output-1');
cy.get('[placeholder="Specify host URL"').clear().type('http://elasticsearch:9200');
cy.intercept('/api/fleet/outputs', {
@@ -71,8 +72,8 @@ describe('Edit settings', () => {
is_default_monitoring: true,
}).as('updateOutputs');
- cy.getBySel('saveApplySettingsBtn').click();
- cy.getBySel(CONFIRM_MODAL_BTN).click();
+ cy.getBySel(SETTINGS_SAVE_BTN).click();
+ cy.getBySel(CONFIRM_MODAL.CONFIRM_BUTTON).click();
cy.wait('@updateOutputs').then((interception) => {
expect(interception.request.body.name).to.equal('output-1');
@@ -80,9 +81,9 @@ describe('Edit settings', () => {
});
it('should allow to create a logstash output', () => {
- cy.getBySel('addOutputBtn').click();
- cy.get('[placeholder="Specify name"]').clear().type('output-logstash-1');
- cy.get('[placeholder="Specify type"]').select('logstash');
+ cy.getBySel(SETTINGS_OUTPUTS.ADD_BTN).click();
+ cy.getBySel(SETTINGS_OUTPUTS.NAME_INPUT).clear().type('output-logstash-1');
+ cy.getBySel(SETTINGS_OUTPUTS.TYPE_INPUT).select('logstash');
cy.get('[placeholder="Specify host"').clear().type('logstash:5044');
cy.get('[placeholder="Specify ssl certificate"]').clear().type('SSL CERTIFICATE');
cy.get('[placeholder="Specify certificate key"]').clear().type('SSL KEY');
@@ -110,7 +111,7 @@ describe('Edit settings', () => {
},
}).as('postLogstashOutput');
- cy.getBySel('saveApplySettingsBtn').click();
+ cy.getBySel(SETTINGS_SAVE_BTN).click();
cy.wait('@postLogstashOutput').then((interception) => {
expect(interception.request.body.name).to.equal('output-logstash-1');
diff --git a/x-pack/plugins/fleet/cypress/integration/fleet_startup.spec.ts b/x-pack/plugins/fleet/cypress/integration/fleet_startup.spec.ts
index 7d7f0d1c5119c..befa2074ac865 100644
--- a/x-pack/plugins/fleet/cypress/integration/fleet_startup.spec.ts
+++ b/x-pack/plugins/fleet/cypress/integration/fleet_startup.spec.ts
@@ -8,9 +8,12 @@
import {
AGENTS_TAB,
ADD_AGENT_BUTTON_TOP,
- AGENT_FLYOUT_CLOSE_BUTTON,
- STANDALONE_TAB,
- AGENT_POLICY_CODE_BLOCK,
+ AGENT_FLYOUT,
+ CREATE_FLEET_SERVER_POLICY_BTN,
+ AGENT_POLICY_CREATE_STATUS_CALLOUT,
+ FLEET_SERVER_HOST_INPUT,
+ ADVANCED_FLEET_SERVER_ADD_HOST_BUTTON,
+ ADVANCED_FLEET_SERVER_GENERATE_SERVICE_TOKEN_BUTTON,
} from '../screens/fleet';
import { cleanupAgentPolicies, unenrollAgent } from '../tasks/cleanup';
import { verifyPolicy, verifyAgentPackage, navigateToTab } from '../tasks/fleet';
@@ -49,11 +52,11 @@ describe('Fleet startup', () => {
it('should create agent policy', () => {
cy.getBySel(ADD_AGENT_BUTTON_TOP).click();
- cy.getBySel(STANDALONE_TAB).click();
+ cy.getBySel(AGENT_FLYOUT.STANDALONE_TAB).click();
cy.intercept('POST', '/api/fleet/agent_policies?sys_monitoring=true').as('createAgentPolicy');
- cy.getBySel('createPolicyBtn').click();
+ cy.getBySel(AGENT_FLYOUT.CREATE_POLICY_BUTTON, { timeout: 10000 }).click();
let agentPolicyId: string;
const startTime = Date.now();
@@ -62,12 +65,12 @@ describe('Fleet startup', () => {
agentPolicyId = xhr.response.body.item.id;
// verify create button changed to dropdown
- cy.getBySel('agentPolicyDropdown');
+ cy.getBySel(AGENT_FLYOUT.POLICY_DROPDOWN);
// verify agent.yml code block has new policy id
- cy.getBySel(AGENT_POLICY_CODE_BLOCK).contains(`id: ${agentPolicyId}`);
+ cy.getBySel(AGENT_FLYOUT.AGENT_POLICY_CODE_BLOCK).contains(`id: ${agentPolicyId}`);
- cy.getBySel(AGENT_FLYOUT_CLOSE_BUTTON).click();
+ cy.getBySel(AGENT_FLYOUT.CLOSE_BUTTON).click();
// verify policy is created and has system package
verifyPolicy('Agent policy 1', ['System']);
@@ -77,11 +80,11 @@ describe('Fleet startup', () => {
});
it('should create Fleet Server policy', () => {
- cy.getBySel('fleetServerFlyoutTab-advanced').click();
- cy.getBySel('createFleetServerPolicyBtn').click();
+ cy.getBySel(AGENT_FLYOUT.ADVANCED_TAB_BUTTON).click();
+ cy.getBySel(CREATE_FLEET_SERVER_POLICY_BTN).click();
// Wait until the success callout is shown before navigating away
- cy.getBySel('agentPolicyCreateStatusCallOut')
+ cy.getBySel(AGENT_POLICY_CREATE_STATUS_CALLOUT)
.should('exist')
.and('have.class', 'euiCallOut--success');
@@ -89,18 +92,18 @@ describe('Fleet startup', () => {
verifyPolicy('Fleet Server policy 1', ['Fleet Server', 'System']);
navigateToTab(AGENTS_TAB);
- cy.getBySel('fleetServerFlyoutTab-advanced').click();
+ cy.getBySel(AGENT_FLYOUT.ADVANCED_TAB_BUTTON).click();
// verify create button changed to dropdown
- cy.getBySel('agentPolicyDropdown');
+ cy.getBySel(AGENT_FLYOUT.POLICY_DROPDOWN);
// verify fleet server enroll command contains created policy id
- cy.getBySel('fleetServerHostInput')
+ cy.getBySel(FLEET_SERVER_HOST_INPUT)
.getBySel('comboBoxSearchInput')
.type('https://localhost:8220');
- cy.getBySel('fleetServerAddHostBtn').click();
- cy.getBySel('fleetServerGenerateServiceTokenBtn').click();
+ cy.getBySel(ADVANCED_FLEET_SERVER_ADD_HOST_BUTTON).click();
+ cy.getBySel(ADVANCED_FLEET_SERVER_GENERATE_SERVICE_TOKEN_BUTTON).click();
cy.get('.euiCodeBlock__code').contains('--fleet-server-policy=fleet-server-policy');
});
});
diff --git a/x-pack/plugins/fleet/cypress/integration/install_assets.spec.ts b/x-pack/plugins/fleet/cypress/integration/install_assets.spec.ts
index 1c6268d2cf66a..81ef56a4b1f52 100644
--- a/x-pack/plugins/fleet/cypress/integration/install_assets.spec.ts
+++ b/x-pack/plugins/fleet/cypress/integration/install_assets.spec.ts
@@ -7,6 +7,9 @@
import type { Interception } from 'cypress/types/net-stubbing';
+import { CONFIRM_MODAL } from '../screens/navigation';
+import { SETTINGS } from '../screens/integrations';
+
describe('Install unverified package assets', () => {
beforeEach(() => {
cy.intercept('POST', '/api/fleet/epm/packages/fleet_server/*', (req) => {
@@ -46,13 +49,13 @@ describe('Install unverified package assets', () => {
it('should show force install modal if package is unverified', () => {
cy.visit('app/integrations/detail/fleet_server/settings');
- cy.getBySel('installAssetsButton').click();
+ cy.getBySel(SETTINGS.INSTALL_ASSETS_BTN).click();
// this action will install x assets modal
- const confirmInstall = cy.getBySel('confirmModalConfirmButton');
+ const confirmInstall = cy.getBySel(CONFIRM_MODAL.CONFIRM_BUTTON);
confirmInstall.click();
// unverified integration force install modal
- const installAnyway = cy.getBySel('confirmModalConfirmButton').contains('Install anyway');
+ const installAnyway = cy.getBySel(CONFIRM_MODAL.CONFIRM_BUTTON).contains('Install anyway');
installAnyway.click();
// cypress 'hack' to get all requests made to an intercepted request
diff --git a/x-pack/plugins/fleet/cypress/integration/integrations_mock.spec.ts b/x-pack/plugins/fleet/cypress/integration/integrations_mock.spec.ts
index 1b969e1a8ca2e..ce207cd3598e2 100644
--- a/x-pack/plugins/fleet/cypress/integration/integrations_mock.spec.ts
+++ b/x-pack/plugins/fleet/cypress/integration/integrations_mock.spec.ts
@@ -7,7 +7,9 @@
import { navigateTo } from '../tasks/navigation';
import { UPDATE_PACKAGE_BTN } from '../screens/integrations';
+import { LOADING_SPINNER, TOAST_CLOSE_BTN } from '../screens/navigation';
import { AGENT_POLICY_SAVE_INTEGRATION } from '../screens/fleet';
+import { INSTALLED_VERSION, INTEGRATION_POLICIES_UPGRADE_CHECKBOX } from '../screens/integrations';
describe('Add Integration - Mock API', () => {
describe('upgrade package and upgrade package policy', () => {
@@ -92,10 +94,10 @@ describe('Add Integration - Mock API', () => {
it('should upgrade policies without integration update', () => {
navigateTo(`app/integrations/detail/apache-${oldVersion}/settings`);
- cy.get('.euiLoadingSpinner').should('not.exist');
- cy.getBySel('installedVersion').contains(oldVersion);
+ cy.getBySel(LOADING_SPINNER).should('not.exist');
+ cy.getBySel(INSTALLED_VERSION).contains(oldVersion);
- cy.get('#upgradePoliciesCheckbox').uncheck({ force: true });
+ cy.getBySel(INTEGRATION_POLICIES_UPGRADE_CHECKBOX).uncheck({ force: true });
cy.intercept(`/api/fleet/epm/packages/apache/${newVersion}`, {
item: {
@@ -109,8 +111,8 @@ describe('Add Integration - Mock API', () => {
}).as('updatePackage');
cy.getBySel(UPDATE_PACKAGE_BTN).click();
cy.wait('@updatePackage');
- cy.get('#upgradePoliciesCheckbox').should('not.exist');
- cy.getBySel('installedVersion').contains(newVersion);
+ cy.getBySel(INTEGRATION_POLICIES_UPGRADE_CHECKBOX).should('not.exist');
+ cy.getBySel(INSTALLED_VERSION).contains(newVersion);
});
it('should upgrade integration policy', () => {
@@ -141,7 +143,7 @@ describe('Add Integration - Mock API', () => {
'/app/fleet/policies/package-1/upgrade-package-policy/apache-2?from=integrations-policy-list'
);
- cy.getBySel('toastCloseButton').click();
+ cy.getBySel(TOAST_CLOSE_BTN).click();
cy.getBySel(AGENT_POLICY_SAVE_INTEGRATION).click();
cy.wait('@updateApachePolicy').then((interception) => {
diff --git a/x-pack/plugins/fleet/cypress/integration/integrations_real.spec.ts b/x-pack/plugins/fleet/cypress/integration/integrations_real.spec.ts
index 1caa90ba1b785..34fa5b7af55ca 100644
--- a/x-pack/plugins/fleet/cypress/integration/integrations_real.spec.ts
+++ b/x-pack/plugins/fleet/cypress/integration/integrations_real.spec.ts
@@ -14,9 +14,8 @@ import {
} from '../tasks/integrations';
import {
AGENT_POLICY_NAME_LINK,
- CONFIRM_MODAL_BTN,
FLYOUT_CLOSE_BTN_SEL,
- INTEGRATIONS_CARD,
+ getIntegrationCard,
INTEGRATION_NAME_LINK,
LATEST_VERSION,
PACKAGE_VERSION,
@@ -24,30 +23,22 @@ import {
SETTINGS_TAB,
UPDATE_PACKAGE_BTN,
INTEGRATIONS_SEARCHBAR_INPUT,
+ SETTINGS,
+ INTEGRATION_POLICIES_UPGRADE_CHECKBOX,
} from '../screens/integrations';
+import { LOADING_SPINNER, CONFIRM_MODAL } from '../screens/navigation';
import { ADD_PACKAGE_POLICY_BTN } from '../screens/fleet';
import { cleanupAgentPolicies } from '../tasks/cleanup';
-describe.skip('Add Integration - Real API', () => {
- const integration = 'Apache';
+describe('Add Integration - Real API', () => {
+ const integration = 'apache';
after(() => {
- cleanupAgentPolicies();
+ deleteIntegrations();
});
- it('should install integration without policy', () => {
- cy.visit('/app/integrations/detail/tomcat/settings');
-
- cy.get('.euiButton').contains('Install Apache Tomcat assets').click();
- cy.get('.euiCallOut').contains('This action will install 1 assets');
- cy.getBySel(CONFIRM_MODAL_BTN).click();
-
- cy.get('.euiLoadingSpinner').should('not.exist');
-
- cy.get('.euiButton').contains('Uninstall Apache Tomcat').click();
- cy.getBySel(CONFIRM_MODAL_BTN).click();
- cy.get('.euiLoadingSpinner').should('not.exist');
- cy.get('.euiButton').contains('Install Apache Tomcat assets');
+ afterEach(() => {
+ cleanupAgentPolicies();
});
function addAndVerifyIntegration() {
@@ -66,27 +57,49 @@ describe.skip('Add Integration - Real API', () => {
navigateTo(INTEGRATIONS);
cy.wait('@packages');
- cy.get('.euiLoadingSpinner').should('not.exist');
- cy.get(INTEGRATIONS_SEARCHBAR_INPUT).type('Apache');
- cy.get(INTEGRATIONS_CARD).contains(integration).click();
+ cy.getBySel(LOADING_SPINNER).should('not.exist');
+ cy.getBySel(INTEGRATIONS_SEARCHBAR_INPUT).type('Apache');
+ cy.getBySel(getIntegrationCard(integration)).click();
addIntegration();
cy.getBySel(INTEGRATION_NAME_LINK).contains('apache-1');
}
- afterEach(() => {
- deleteIntegrations(integration);
+ it('should install integration without policy', () => {
+ cy.visit('/app/integrations/detail/tomcat/settings');
+
+ cy.getBySel(SETTINGS.INSTALL_ASSETS_BTN).click();
+ cy.get('.euiCallOut').contains('This action will install 1 assets');
+ cy.getBySel(CONFIRM_MODAL.CONFIRM_BUTTON).click();
+
+ cy.getBySel(LOADING_SPINNER).should('not.exist');
+
+ cy.getBySel(SETTINGS.UNINSTALL_ASSETS_BTN).click();
+ cy.getBySel(CONFIRM_MODAL.CONFIRM_BUTTON).click();
+ cy.getBySel(LOADING_SPINNER).should('not.exist');
+ cy.getBySel(SETTINGS.INSTALL_ASSETS_BTN).should('exist');
});
+
it('should display Apache integration in the Policies list once installed ', () => {
addAndVerifyIntegration();
cy.getBySel(AGENT_POLICY_NAME_LINK).contains('Agent policy 1');
});
it('should add integration to policy', () => {
- cy.request('/api/fleet/agent_policies').then((response: any) => {
- const agentPolicyId = response.body.items
- .filter((policy: any) => policy.name === 'Agent policy 1')
- .map((policy: any) => policy.id);
+ const agentPolicyId = 'policy_1';
+ cy.request({
+ method: 'POST',
+ url: `/api/fleet/agent_policies`,
+ body: {
+ id: `${agentPolicyId}`,
+ name: 'Agent policy 1',
+ description: 'desc',
+ namespace: 'default',
+ monitoring_enabled: ['logs', 'metrics'],
+ },
+ headers: { 'kbn-xsrf': 'cypress' },
+ });
+ cy.request('/api/fleet/agent_policies').then((response: any) => {
cy.visit(`/app/fleet/policies/${agentPolicyId}`);
cy.intercept(
@@ -104,9 +117,9 @@ describe.skip('Add Integration - Real API', () => {
cy.getBySel(ADD_PACKAGE_POLICY_BTN).click();
cy.wait('@packages');
- cy.get('.euiLoadingSpinner').should('not.exist');
- cy.get(INTEGRATIONS_SEARCHBAR_INPUT).type('Apache');
- cy.get(INTEGRATIONS_CARD).contains(integration).click();
+ cy.getBySel(LOADING_SPINNER).should('not.exist');
+ cy.getBySel(INTEGRATIONS_SEARCHBAR_INPUT).type('Apache');
+ cy.getBySel(getIntegrationCard(integration)).click();
addIntegration({ useExistingPolicy: true });
cy.get('.euiBasicTable-loading').should('not.exist');
cy.get('.euiTitle').contains('Agent policy 1');
@@ -120,7 +133,7 @@ describe.skip('Add Integration - Real API', () => {
installPackageWithVersion('apache', oldVersion);
navigateTo(`app/integrations/detail/apache-${oldVersion}/policies`);
- addIntegration({ useExistingPolicy: true });
+ addIntegration();
cy.getBySel(INTEGRATION_NAME_LINK).contains('apache-');
cy.getBySel(PACKAGE_VERSION).contains(oldVersion);
@@ -129,11 +142,11 @@ describe.skip('Add Integration - Real API', () => {
cy.getBySel(SETTINGS_TAB).click();
cy.getBySel(UPDATE_PACKAGE_BTN).click();
- cy.getBySel(CONFIRM_MODAL_BTN).click();
+ cy.getBySel(CONFIRM_MODAL.CONFIRM_BUTTON).click();
cy.getBySel(LATEST_VERSION).then(($title) => {
const newVersion = $title.text();
- cy.get('#upgradePoliciesCheckbox').should('not.exist');
+ cy.getBySel(INTEGRATION_POLICIES_UPGRADE_CHECKBOX).should('not.exist');
cy.getBySel(POLICIES_TAB).click();
cy.getBySel(PACKAGE_VERSION).contains(oldVersion).should('not.exist');
cy.getBySel(PACKAGE_VERSION).contains(newVersion);
diff --git a/x-pack/plugins/fleet/cypress/integration/package_policy.spec.ts b/x-pack/plugins/fleet/cypress/integration/package_policy.spec.ts
index b2fa21371539d..8b1569574c4e7 100644
--- a/x-pack/plugins/fleet/cypress/integration/package_policy.spec.ts
+++ b/x-pack/plugins/fleet/cypress/integration/package_policy.spec.ts
@@ -4,6 +4,7 @@
* 2.0; you may not use this file except in compliance with the Elastic License
* 2.0.
*/
+import { TOAST_CLOSE_BTN } from '../screens/navigation';
describe('Edit package policy', () => {
const policyConfig = {
@@ -109,7 +110,7 @@ describe('Edit package policy', () => {
it('should edit package policy', () => {
cy.visit('/app/fleet/policies/fleet-server-policy/edit-integration/policy-1');
- cy.getBySel('toastCloseButton').click();
+ cy.getBySel(TOAST_CLOSE_BTN).click();
cy.getBySel('packagePolicyDescriptionInput').clear().type('desc');
cy.intercept('PUT', '/api/fleet/package_policies/policy-1', {
diff --git a/x-pack/plugins/fleet/cypress/integration/privileges_fleet_all_integrations_read.spec.ts b/x-pack/plugins/fleet/cypress/integration/privileges_fleet_all_integrations_read.spec.ts
index 327ba39e65377..517687a0bcd19 100644
--- a/x-pack/plugins/fleet/cypress/integration/privileges_fleet_all_integrations_read.spec.ts
+++ b/x-pack/plugins/fleet/cypress/integration/privileges_fleet_all_integrations_read.spec.ts
@@ -15,6 +15,7 @@ import {
import { loginWithUserAndWaitForPage, logout } from '../tasks/login';
import { navigateToTab, createAgentPolicy } from '../tasks/fleet';
import { cleanupAgentPolicies, unenrollAgent } from '../tasks/cleanup';
+import { getIntegrationCard } from '../screens/integrations';
import {
FLEET_SERVER_MISSING_PRIVILEGES_TITLE,
@@ -24,7 +25,7 @@ import {
AGENT_POLICY_SAVE_INTEGRATION,
ADD_PACKAGE_POLICY_BTN,
} from '../screens/fleet';
-import { ADD_POLICY_BTN, AGENT_POLICY_NAME_LINK } from '../screens/integrations';
+import { ADD_INTEGRATION_POLICY_BTN, AGENT_POLICY_NAME_LINK } from '../screens/integrations';
const rolesToCreate = [FleetAllIntegrReadRole];
const usersToCreate = [FleetAllIntegrReadUser];
@@ -81,8 +82,8 @@ describe('When the user has All privilege for Fleet but Read for integrations',
describe('Integrations', () => {
it('are visible but cannot be added', () => {
loginWithUserAndWaitForPage(INTEGRATIONS, FleetAllIntegrReadUser);
- cy.getBySel('integration-card:epr:apache').click();
- cy.getBySel(ADD_POLICY_BTN).should('be.disabled');
+ cy.getBySel(getIntegrationCard('apache')).click();
+ cy.getBySel(ADD_INTEGRATION_POLICY_BTN).should('be.disabled');
});
});
});
diff --git a/x-pack/plugins/fleet/cypress/integration/privileges_fleet_none_integrations_all.spec.ts b/x-pack/plugins/fleet/cypress/integration/privileges_fleet_none_integrations_all.spec.ts
index 68fcecb76de21..71e7d948f928a 100644
--- a/x-pack/plugins/fleet/cypress/integration/privileges_fleet_none_integrations_all.spec.ts
+++ b/x-pack/plugins/fleet/cypress/integration/privileges_fleet_none_integrations_all.spec.ts
@@ -14,7 +14,7 @@ import {
} from '../tasks/privileges';
import { loginWithUserAndWaitForPage, logout } from '../tasks/login';
-import { ADD_POLICY_BTN } from '../screens/integrations';
+import { ADD_INTEGRATION_POLICY_BTN, getIntegrationCard } from '../screens/integrations';
const rolesToCreate = [FleetNoneIntegrAllRole];
const usersToCreate = [FleetNoneIntegrAllUser];
@@ -34,7 +34,7 @@ describe('When the user has All privileges for Integrations but None for for Fle
it('Integrations are visible but cannot be added', () => {
loginWithUserAndWaitForPage(INTEGRATIONS, FleetNoneIntegrAllUser);
- cy.getBySel('integration-card:epr:apache').click();
- cy.getBySel(ADD_POLICY_BTN).should('be.disabled');
+ cy.getBySel(getIntegrationCard('apache')).click();
+ cy.getBySel(ADD_INTEGRATION_POLICY_BTN).should('be.disabled');
});
});
diff --git a/x-pack/plugins/fleet/cypress/screens/fleet.ts b/x-pack/plugins/fleet/cypress/screens/fleet.ts
index 72dd6486c6843..a9df1dc4d8ef1 100644
--- a/x-pack/plugins/fleet/cypress/screens/fleet.ts
+++ b/x-pack/plugins/fleet/cypress/screens/fleet.ts
@@ -7,16 +7,13 @@
export const ADD_AGENT_BUTTON = 'addAgentButton';
export const ADD_AGENT_BUTTON_TOP = 'addAgentBtnTop';
-export const CREATE_POLICY_BUTTON = 'createPolicyBtn';
-export const AGENT_FLYOUT_CLOSE_BUTTON = 'euiFlyoutCloseButton';
-export const AGENT_POLICY_CODE_BLOCK = 'agentPolicyCodeBlock';
export const AGENTS_TAB = 'fleet-agents-tab';
export const AGENT_POLICIES_TAB = 'fleet-agent-policies-tab';
export const ENROLLMENT_TOKENS_TAB = 'fleet-enrollment-tokens-tab';
export const DATA_STREAMS_TAB = 'fleet-datastreams-tab';
export const SETTINGS_TAB = 'fleet-settings-tab';
-export const STANDALONE_TAB = 'standaloneTab';
+
export const MISSING_PRIVILEGES_TITLE = 'missingPrivilegesPromptTitle';
export const MISSING_PRIVILEGES_MESSAGE = 'missingPrivilegesPromptMessage';
export const FLEET_SERVER_MISSING_PRIVILEGES_MESSAGE = 'fleetServerMissingPrivilegesMessage';
@@ -26,20 +23,57 @@ export const PACKAGE_POLICY_TABLE_LINK = 'PackagePoliciesTableLink';
export const ADD_PACKAGE_POLICY_BTN = 'addPackagePolicyButton';
export const GENERATE_FLEET_SERVER_POLICY_BUTTON = 'generateFleetServerPolicyButton';
export const ADD_FLEET_SERVER_HEADER = 'addFleetServerHeader';
-export const AGENTS_QUICK_START_TAB_BUTTON = 'fleetServerFlyoutTab-quickStart';
-export const AGENTS_ADVANCED_TAB_BUTTON = 'fleetServerFlyoutTab-advanced';
+
export const PLATFORM_TYPE_LINUX_BUTTON = 'platformTypeLinux';
export const ADVANCED_FLEET_SERVER_ADD_HOST_BUTTON = 'fleetServerAddHostBtn';
export const ADVANCED_FLEET_SERVER_GENERATE_SERVICE_TOKEN_BUTTON =
'fleetServerGenerateServiceTokenBtn';
-export const AGENT_POLICIES_CREATE_AGENT_POLICY_BUTTON = 'createAgentPolicyButton';
-export const AGENT_POLICIES_CREATE_AGENT_POLICY_FLYOUT_TITLE = 'createAgentPolicyFlyoutTitle';
+
+export const CREATE_FLEET_SERVER_POLICY_BTN = 'createFleetServerPolicyBtn';
+
export const AGENT_POLICY_CREATE_AGENT_POLICY_NAME_FIELD = 'createAgentPolicyNameField';
export const AGENT_POLICIES_FLYOUT_ADVANCED_DEFAULT_NAMESPACE_HEADER = 'defaultNamespaceHeader';
export const AGENT_POLICY_FLYOUT_CREATE_BUTTON = 'createAgentPolicyFlyoutBtn';
-export const ENROLLMENT_TOKENS_CREATE_TOKEN_BUTTON = 'createEnrollmentTokenButton';
-export const ENROLLMENT_TOKENS_CREATE_TOKEN_NAME_FIELD = 'createEnrollmentTokenNameField';
+
+export const ENROLLMENT_TOKENS = {
+ CREATE_TOKEN_BUTTON: 'createEnrollmentTokenButton',
+ CREATE_TOKEN_MODAL_NAME_FIELD: 'createEnrollmentTokenNameField',
+ CREATE_TOKEN_MODAL_SELECT_FIELD: 'createEnrollmentTokenSelectField',
+ LIST_TABLE: 'enrollmentTokenListTable',
+ TABLE_REVOKE_BTN: 'enrollmentTokenTable.revokeBtn',
+};
export const SETTINGS_FLEET_SERVER_HOST_HEADING = 'fleetServerHostHeader';
+export const SETTINGS_SAVE_BTN = 'saveApplySettingsBtn';
+
+export const AGENT_POLICY_SYSTEM_MONITORING_CHECKBOX = 'agentPolicyFormSystemMonitoringCheckbox';
+export const INSTALL_INTEGRATIONS_ADVANCE_OPTIONS_BTN = 'AgentPolicyAdvancedOptions.AccordionBtn';
+export const AGENT_POLICY_CREATE_STATUS_CALLOUT = 'agentPolicyCreateStatusCallOut';
+export const FLEET_SERVER_HOST_INPUT = 'fleetServerHostInput';
+export const EXISTING_HOSTS_TAB = 'existingHostsTab';
+export const NEW_HOSTS_TAB = 'newHostsTab';
+
+export const CURRENT_BULK_UPGRADES_CALLOUT = {
+ ABORT_BTN: 'currentBulkUpgrade.abortBtn',
+};
+
+export const AGENT_FLYOUT = {
+ CREATE_POLICY_BUTTON: 'createPolicyBtn',
+ CLOSE_BUTTON: 'euiFlyoutCloseButton',
+ POLICY_DROPDOWN: 'agentPolicyDropdown',
+ QUICK_START_TAB_BUTTON: 'fleetServerFlyoutTab-quickStart',
+ ADVANCED_TAB_BUTTON: 'fleetServerFlyoutTab-advanced',
+ AGENT_POLICY_CODE_BLOCK: 'agentPolicyCodeBlock',
+ STANDALONE_TAB: 'standaloneTab',
+ CONFIRM_AGENT_ENROLLMENT_BUTTON: 'ConfirmAgentEnrollmentButton',
+ INCOMING_DATA_CONFIRMED_CALL_OUT: 'IncomingDataConfirmedCallOut',
+};
+
+export const AGENT_POLICIES_CREATE_AGENT_POLICY_FLYOUT = {
+ TITLE: 'createAgentPolicyFlyoutTitle',
+ CREATE_BUTTON: 'createAgentPolicyButton',
+ COLLECT_LOGS_CHECKBOX: 'collectLogsCheckbox',
+ COLLECT_METRICS_CHECKBOX: 'collectMetricsCheckbox',
+};
export const AGENT_BINARY_SOURCES_TABLE = 'AgentDownloadSourcesTable';
export const AGENT_BINARY_SOURCES_TABLE_ACTIONS = {
@@ -59,13 +93,24 @@ export const AGENT_BINARY_SOURCES_FLYOUT = {
CANCEL_BUTTON: 'editDownloadSourcesFlyout.cancelBtn',
};
-export const ADD_AGENT_FLYOUT = {
- CONFIRM_AGENT_ENROLLMENT_BUTTON: 'ConfirmAgentEnrollmentButton',
- INCOMING_DATA_CONFIRMED_CALL_OUT: 'IncomingDataConfirmedCallOut',
+export const SETTINGS_OUTPUTS = {
+ EDIT_BTN: 'editOutputBtn',
+ ADD_BTN: 'addOutputBtn',
+ EDIT_HOSTS_BTN: 'editHostsBtn',
+ NAME_INPUT: 'settingsOutputsFlyout.nameInput',
+ TYPE_INPUT: 'settingsOutputsFlyout.typeInput',
};
-export const CONFIRM_MODAL_CONFIRM_BUTTON = 'confirmModalConfirmButton';
-export const CONFIRM_MODAL_CANCEL_BUTTON = 'confirmModalCancelButton';
export const AGENT_POLICY_FORM = {
DOWNLOAD_SOURCE_SELECT: 'agentPolicyForm.downloadSource.select',
};
+
+export const FLEET_AGENT_LIST_PAGE = {
+ TABLE: 'fleetAgentListTable',
+ STATUS_FILTER: 'agentList.statusFilter',
+ POLICY_FILTER: 'agentList.policyFilter',
+ QUERY_INPUT: 'agentList.queryInput',
+ SHOW_UPGRADEABLE: 'agentList.showUpgradeable',
+ CHECKBOX_SELECT_ALL: 'checkboxSelectAll',
+ BULK_ACTIONS_BUTTON: 'agentBulkActionsButton',
+};
diff --git a/x-pack/plugins/fleet/cypress/screens/integrations.ts b/x-pack/plugins/fleet/cypress/screens/integrations.ts
index 929e36d191230..3915c6600baaa 100644
--- a/x-pack/plugins/fleet/cypress/screens/integrations.ts
+++ b/x-pack/plugins/fleet/cypress/screens/integrations.ts
@@ -5,17 +5,13 @@
* 2.0.
*/
-export const ADD_POLICY_BTN = 'addIntegrationPolicyButton';
+export const ADD_INTEGRATION_POLICY_BTN = 'addIntegrationPolicyButton';
export const CREATE_PACKAGE_POLICY_SAVE_BTN = 'createPackagePolicySaveButton';
-export const INTEGRATIONS_CARD = '.euiCard__titleButton';
export const INTEGRATION_NAME_LINK = 'integrationNameLink';
export const AGENT_POLICY_NAME_LINK = 'agentPolicyNameLink';
export const AGENT_ACTIONS_BTN = 'agentActionsBtn';
-export const CONFIRM_MODAL_BTN = 'confirmModalConfirmButton';
-export const CONFIRM_MODAL_BTN_SEL = `[data-test-subj=${CONFIRM_MODAL_BTN}]`;
-
export const FLYOUT_CLOSE_BTN_SEL = '[data-test-subj="euiFlyoutCloseButton"]';
export const SETTINGS_TAB = 'tab-settings';
@@ -23,7 +19,17 @@ export const POLICIES_TAB = 'tab-policies';
export const ADVANCED_TAB = 'tab-custom';
export const UPDATE_PACKAGE_BTN = 'updatePackageBtn';
-export const LATEST_VERSION = 'latestVersion';
+export const LATEST_VERSION = 'epmSettings.latestVersionTitle';
+export const INSTALLED_VERSION = 'epmSettings.installedVersionTitle';
export const PACKAGE_VERSION = 'packageVersionText';
export const INTEGRATIONS_SEARCHBAR_INPUT = 'epmList.searchBar';
+
+export const SETTINGS = {
+ INSTALL_ASSETS_BTN: 'installAssetsButton',
+ UNINSTALL_ASSETS_BTN: 'uninstallAssetsButton',
+};
+
+export const INTEGRATION_POLICIES_UPGRADE_CHECKBOX = 'epmDetails.upgradePoliciesCheckbox';
+
+export const getIntegrationCard = (integration: string) => `integration-card:epr:${integration}`;
diff --git a/x-pack/plugins/fleet/cypress/screens/navigation.ts b/x-pack/plugins/fleet/cypress/screens/navigation.ts
index 76b73711db495..b8f6bea719e8a 100644
--- a/x-pack/plugins/fleet/cypress/screens/navigation.ts
+++ b/x-pack/plugins/fleet/cypress/screens/navigation.ts
@@ -7,3 +7,13 @@
export const TOGGLE_NAVIGATION_BTN = 'toggleNavButton';
export const NAV_APP_LINK = 'collapsibleNavAppLink';
+export const LOADING_SPINNER = '.euiLoadingSpinner';
+export const TOAST_CLOSE_BTN = 'toastCloseButton';
+
+// these selectors are part of a common component and so are used everywhere
+export const CONFIRM_MODAL = {
+ CONFIRM_BUTTON: 'confirmModalConfirmButton',
+ CANCEL_BUTTON: 'confirmModalCancelButton',
+};
+
+export const CONFIRM_MODAL_BTN_SEL = `[data-test-subj=${CONFIRM_MODAL.CONFIRM_BUTTON}]`;
diff --git a/x-pack/plugins/fleet/cypress/tasks/cleanup.ts b/x-pack/plugins/fleet/cypress/tasks/cleanup.ts
index b0d18fa9cdceb..2a1e57271f08a 100644
--- a/x-pack/plugins/fleet/cypress/tasks/cleanup.ts
+++ b/x-pack/plugins/fleet/cypress/tasks/cleanup.ts
@@ -48,3 +48,18 @@ export function cleanupDownloadSources() {
});
});
}
+
+export function deleteFleetServerDocs(ignoreUnavailable: boolean = false) {
+ cy.task('deleteDocsByQuery', {
+ index: '.fleet-servers',
+ query: { match_all: {} },
+ ignoreUnavailable,
+ });
+}
+export function deleteAgentDocs(ignoreUnavailable: boolean = false) {
+ cy.task('deleteDocsByQuery', {
+ index: '.fleet-agents',
+ query: { match_all: {} },
+ ignoreUnavailable,
+ });
+}
diff --git a/x-pack/plugins/fleet/cypress/tasks/fleet.ts b/x-pack/plugins/fleet/cypress/tasks/fleet.ts
index 4a23daf7a8380..35d6c5cf5dd79 100644
--- a/x-pack/plugins/fleet/cypress/tasks/fleet.ts
+++ b/x-pack/plugins/fleet/cypress/tasks/fleet.ts
@@ -6,13 +6,14 @@
*/
import {
+ AGENT_FLYOUT,
AGENT_POLICIES_TAB,
ENROLLMENT_TOKENS_TAB,
ADD_AGENT_BUTTON_TOP,
- CREATE_POLICY_BUTTON,
- AGENT_FLYOUT_CLOSE_BUTTON,
- STANDALONE_TAB,
+ PACKAGE_POLICY_TABLE_LINK,
} from '../screens/fleet';
+import { LOADING_SPINNER } from '../screens/navigation';
+import { getIntegrationCard } from '../screens/integrations';
export function createAgentPolicy() {
cy.intercept({
@@ -20,11 +21,11 @@ export function createAgentPolicy() {
method: 'POST',
}).as('postAgentPolicy');
cy.getBySel(ADD_AGENT_BUTTON_TOP).click();
- cy.getBySel(STANDALONE_TAB).click();
- cy.getBySel(CREATE_POLICY_BUTTON).click();
+ cy.getBySel(AGENT_FLYOUT.STANDALONE_TAB).click();
+ cy.getBySel(AGENT_FLYOUT.CREATE_POLICY_BUTTON).click();
cy.wait('@postAgentPolicy');
- cy.getBySel(AGENT_FLYOUT_CLOSE_BUTTON).click();
+ cy.getBySel(AGENT_FLYOUT.CLOSE_BUTTON).click();
}
export function navigateToTab(tab: string) {
@@ -34,7 +35,7 @@ export function navigateToTab(tab: string) {
export function navigateToAgentPolicy(name: string) {
cy.get('.euiLink').contains(name).click();
- cy.get('.euiLoadingSpinner').should('not.exist');
+ cy.getBySel(LOADING_SPINNER).should('not.exist');
}
export function navigateToEnrollmentTokens() {
@@ -48,7 +49,7 @@ export function verifyPolicy(name: string, integrations: string[]) {
navigateToAgentPolicy(name);
integrations.forEach((integration) => {
- cy.get('.euiLink').contains(integration);
+ cy.getBySel(PACKAGE_POLICY_TABLE_LINK).contains(integration);
});
cy.get('.euiButtonEmpty').contains('View all agent policies').click();
@@ -60,16 +61,5 @@ export function verifyPolicy(name: string, integrations: string[]) {
export function verifyAgentPackage() {
cy.visit('/app/integrations/installed');
- cy.getBySel('integration-card:epr:elastic_agent');
-}
-
-export function setFleetServerHost(host = 'https://fleetserver:8220') {
- cy.request({
- method: 'PUT',
- url: '/api/fleet/settings',
- headers: { 'kbn-xsrf': 'xx' },
- body: {
- fleet_server_hosts: [host],
- },
- });
+ cy.getBySel(getIntegrationCard('elastic_agent'));
}
diff --git a/x-pack/plugins/fleet/cypress/tasks/fleet_server.ts b/x-pack/plugins/fleet/cypress/tasks/fleet_server.ts
new file mode 100644
index 0000000000000..946ded57e738f
--- /dev/null
+++ b/x-pack/plugins/fleet/cypress/tasks/fleet_server.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 { createAgentDoc } from './agents';
+
+const FLEET_SERVER_POLICY_ID = 'fleet-server-policy';
+
+// Create a Fleet server policy
+export function setupFleetServer() {
+ let policyId: string;
+ let kibanaVersion: string;
+
+ cy.request({
+ method: 'POST',
+ url: '/api/fleet/agent_policies',
+ headers: { 'kbn-xsrf': 'xx' },
+ body: {
+ id: FLEET_SERVER_POLICY_ID,
+ name: 'Fleet Server policy',
+ namespace: 'default',
+ has_fleet_server: true,
+ },
+ }).then((response: any) => {
+ policyId = response.body.item.id;
+ });
+
+ cy.getKibanaVersion().then((version) => {
+ kibanaVersion = version;
+ });
+
+ // setup Fleet server
+ cy.wrap(null).then(() => {
+ cy.task('insertDocs', {
+ index: '.fleet-agents',
+ docs: [createAgentDoc('fleet-server', policyId, 'online', kibanaVersion)],
+ });
+ cy.task('insertDocs', {
+ index: '.fleet-servers',
+ docs: [
+ {
+ '@timestamp': new Date().toISOString(),
+ },
+ ],
+ });
+ setFleetServerHost();
+ });
+}
+
+export function setFleetServerHost(host = 'https://fleetserver:8220') {
+ cy.request({
+ method: 'PUT',
+ url: '/api/fleet/settings',
+ headers: { 'kbn-xsrf': 'xx' },
+ body: {
+ fleet_server_hosts: [host],
+ },
+ });
+}
diff --git a/x-pack/plugins/fleet/cypress/tasks/integrations.ts b/x-pack/plugins/fleet/cypress/tasks/integrations.ts
index 7e266dce523d5..71a8c3cd2f9a7 100644
--- a/x-pack/plugins/fleet/cypress/tasks/integrations.ts
+++ b/x-pack/plugins/fleet/cypress/tasks/integrations.ts
@@ -6,27 +6,34 @@
*/
import {
- ADD_POLICY_BTN,
- CONFIRM_MODAL_BTN,
+ ADD_INTEGRATION_POLICY_BTN,
CREATE_PACKAGE_POLICY_SAVE_BTN,
FLYOUT_CLOSE_BTN_SEL,
} from '../screens/integrations';
+import { AGENT_POLICY_SYSTEM_MONITORING_CHECKBOX, EXISTING_HOSTS_TAB } from '../screens/fleet';
+import { TOAST_CLOSE_BTN, CONFIRM_MODAL } from '../screens/navigation';
+
export const addIntegration = ({ useExistingPolicy } = { useExistingPolicy: false }) => {
- cy.getBySel(ADD_POLICY_BTN).click();
+ cy.getBySel(ADD_INTEGRATION_POLICY_BTN).click();
if (useExistingPolicy) {
- cy.get('#existing').click();
+ cy.getBySel(EXISTING_HOSTS_TAB).click();
} else {
// speeding up creating with unchecking system and agent integration
- cy.getBySel('agentPolicyFormSystemMonitoringCheckbox').uncheck({ force: true });
- cy.getBySel('advancedOptionsBtn').find('.euiAccordion__button').click();
- cy.get('*[id^="logs_"]').uncheck({ force: true });
- cy.get('*[id^="metrics_"]').uncheck({ force: true });
+ cy.getBySel(AGENT_POLICY_SYSTEM_MONITORING_CHECKBOX).uncheck({ force: true });
+ cy.get('.euiAccordion__button').click();
+
+ cy.get('*[id^="logs_"]').uncheck({
+ force: true,
+ });
+ cy.get('*[id^="metrics_"]').uncheck({
+ force: true,
+ });
}
- cy.getBySel('toastCloseButton').click();
+ cy.getBySel(TOAST_CLOSE_BTN).click();
cy.getBySel(CREATE_PACKAGE_POLICY_SAVE_BTN).click();
// sometimes agent is assigned to default policy, sometimes not
- cy.getBySel(CONFIRM_MODAL_BTN).click();
+ cy.getBySel(CONFIRM_MODAL.CONFIRM_BUTTON).click();
cy.getBySel(CREATE_PACKAGE_POLICY_SAVE_BTN).should('not.exist');
clickIfVisible(FLYOUT_CLOSE_BTN_SEL);
@@ -40,14 +47,14 @@ export function clickIfVisible(selector: string) {
});
}
-export const deleteIntegrations = async (integration: string) => {
+export const deleteIntegrations = async () => {
const ids: string[] = [];
cy.request('/api/fleet/package_policies').then((response: any) => {
response.body.items.forEach((policy: any) => ids.push(policy.id));
cy.request({
url: `/api/fleet/package_policies/delete`,
headers: { 'kbn-xsrf': 'cypress' },
- body: `{ "packagePolicyIds": ${JSON.stringify(ids)} }`,
+ body: `{ "packagePolicyIds": ${JSON.stringify(ids)}, "force": true }`,
method: 'POST',
});
});
diff --git a/x-pack/plugins/fleet/public/applications/fleet/sections/agent_policy/components/agent_policy_advanced_fields/index.tsx b/x-pack/plugins/fleet/public/applications/fleet/sections/agent_policy/components/agent_policy_advanced_fields/index.tsx
index d9e44c6207fc4..f8eab1fe8513e 100644
--- a/x-pack/plugins/fleet/public/applications/fleet/sections/agent_policy/components/agent_policy_advanced_fields/index.tsx
+++ b/x-pack/plugins/fleet/public/applications/fleet/sections/agent_policy/components/agent_policy_advanced_fields/index.tsx
@@ -182,6 +182,7 @@ export const AgentPolicyAdvancedOptionsContent: React.FunctionComponent =
options={[
{
id: `${dataTypes.Logs}_${monitoringCheckboxIdSuffix}`,
+ 'data-test-subj': 'collectLogsCheckbox',
label: (
<>
=
},
{
id: `${dataTypes.Metrics}_${monitoringCheckboxIdSuffix}`,
+ 'data-test-subj': 'collectMetricsCheckbox',
label: (
<>
= ({
const tabs = [
{
id: SelectedPolicyTab.NEW,
+ 'data-test-subj': 'newHostsTab',
name: 'New hosts',
content: (
= ({
},
{
id: SelectedPolicyTab.EXISTING,
+ 'data-test-subj': 'existingHostsTab',
name: 'Existing hosts',
content: (
{
= () => {
+ data-test-subj="enrollmentTokenListTable"
loading={isLoading}
hasActions={true}
noItemsMessage={
diff --git a/x-pack/plugins/fleet/public/applications/fleet/sections/settings/components/edit_output_flyout/index.tsx b/x-pack/plugins/fleet/public/applications/fleet/sections/settings/components/edit_output_flyout/index.tsx
index 3d0e9b2801394..02e476ce1ed3d 100644
--- a/x-pack/plugins/fleet/public/applications/fleet/sections/settings/components/edit_output_flyout/index.tsx
+++ b/x-pack/plugins/fleet/public/applications/fleet/sections/settings/components/edit_output_flyout/index.tsx
@@ -116,6 +116,7 @@ export const EditOutputFlyout: React.FunctionComponent =
{...inputs.nameInput.formRowProps}
>
=
>
=
)}
{isESOutput && (
= memo(({ packageInfo, theme$ }: Prop
/>
-
+
{installedVersion}
|
@@ -267,7 +267,7 @@ export const SettingsPage: React.FC = memo(({ packageInfo, theme$ }: Prop
/>
-
+
{latestVersion}
|
diff --git a/x-pack/plugins/fleet/public/applications/integrations/sections/epm/screens/detail/settings/uninstall_button.tsx b/x-pack/plugins/fleet/public/applications/integrations/sections/epm/screens/detail/settings/uninstall_button.tsx
index 73780e23a1a7e..df472c765c09a 100644
--- a/x-pack/plugins/fleet/public/applications/integrations/sections/epm/screens/detail/settings/uninstall_button.tsx
+++ b/x-pack/plugins/fleet/public/applications/integrations/sections/epm/screens/detail/settings/uninstall_button.tsx
@@ -58,6 +58,7 @@ export const UninstallButton: React.FunctionComponent = ({
return canRemovePackages ? (
<>
setIsUninstallModalVisible(true)}
diff --git a/x-pack/plugins/fleet/public/applications/integrations/sections/epm/screens/detail/settings/update_button.tsx b/x-pack/plugins/fleet/public/applications/integrations/sections/epm/screens/detail/settings/update_button.tsx
index cc11dd6819695..526c50aca1b96 100644
--- a/x-pack/plugins/fleet/public/applications/integrations/sections/epm/screens/detail/settings/update_button.tsx
+++ b/x-pack/plugins/fleet/public/applications/integrations/sections/epm/screens/detail/settings/update_button.tsx
@@ -326,6 +326,7 @@ export const UpdateButton: React.FunctionComponent = ({
},
}}
id="upgradePoliciesCheckbox"
+ data-test-subj="epmDetails.upgradePoliciesCheckbox"
disabled={!canUpgradePackages}
checked={upgradePackagePolicies}
onChange={handleUpgradePackagePoliciesChange}
diff --git a/x-pack/plugins/fleet/public/components/new_enrollment_key_modal.tsx b/x-pack/plugins/fleet/public/components/new_enrollment_key_modal.tsx
index c611c9a543d73..8689e920d2a0f 100644
--- a/x-pack/plugins/fleet/public/components/new_enrollment_key_modal.tsx
+++ b/x-pack/plugins/fleet/public/components/new_enrollment_key_modal.tsx
@@ -131,7 +131,12 @@ export const NewEnrollmentTokenModal: React.FunctionComponent = ({
})}
{...form.policyIdInput.formRowProps}
>
-
+
diff --git a/x-pack/plugins/monitoring/dev_docs/how_to/apm_tracing.md b/x-pack/plugins/monitoring/dev_docs/how_to/apm_tracing.md
index 4356a440f73f9..de49f7ceef50f 100644
--- a/x-pack/plugins/monitoring/dev_docs/how_to/apm_tracing.md
+++ b/x-pack/plugins/monitoring/dev_docs/how_to/apm_tracing.md
@@ -15,7 +15,11 @@ All data will be available on the shared APM cluster. See (internal) https://doc
## For ESS
-Add the settings into the `user_settings_override_yaml` deployment configuration within `kibana.plan.kibana` section as escaped YAML inside JSON.
+ESS clusters in the Elastic organization are configured to send data to the cloud overview cluster automatically (via the cloud `KibanaInternalApmSettings` class). Search for `label.deploymentId: ` in a kibana dashboard or APM UI.
+
+For clusters outside the Elastic organization, or to send APM data to a different deployment, you can add the APM settings into the `user_settings_override_yaml` deployment configuration within `kibana.plan.kibana` section as escaped YAML inside JSON.
+
+For example:
```json
{
@@ -41,4 +45,4 @@ elastic.apm.metricsInterval: 120s
elastic.apm.captureSpanStackTraces: false
```
-When running in ECE you can update `kibana.yml` settings via the ECE web UI under "Edit user setting" for the kibana nodes in the deployment.
\ No newline at end of file
+When running in ECE you can update `kibana.yml` settings via the ECE web UI under "Edit user setting" for the kibana nodes in the deployment.
diff --git a/x-pack/plugins/monitoring/public/application/contexts/global_state_context.tsx b/x-pack/plugins/monitoring/public/application/contexts/global_state_context.tsx
index 71180f2c2c92d..7d5ab0be65033 100644
--- a/x-pack/plugins/monitoring/public/application/contexts/global_state_context.tsx
+++ b/x-pack/plugins/monitoring/public/application/contexts/global_state_context.tsx
@@ -4,9 +4,10 @@
* 2.0; you may not use this file except in compliance with the Elastic License
* 2.0.
*/
-import React, { createContext } from 'react';
+import React, { createContext, useState } from 'react';
import type { TimeRange } from '@kbn/es-query';
import { RefreshInterval } from '@kbn/data-plugin/public';
+import useUnmount from 'react-use/lib/useUnmount';
import { GlobalState } from '../../url_state';
import { MonitoringStartPluginDependencies, MonitoringStartServices } from '../../types';
import { Legacy } from '../../legacy_shims';
@@ -42,9 +43,11 @@ export const GlobalStateProvider: React.FC = ({
children,
}) => {
const localState: State = {};
- const state = new GlobalState(query, toasts, localState as { [key: string]: unknown });
+ const [globalState] = useState(
+ () => new GlobalState(query, toasts, localState as { [key: string]: unknown })
+ );
- const initialState: any = state.getState();
+ const initialState: any = globalState.getState();
for (const key in initialState) {
if (!initialState.hasOwnProperty(key)) {
continue;
@@ -55,7 +58,7 @@ export const GlobalStateProvider: React.FC = ({
localState.save = () => {
const newState = { ...localState };
delete newState.save;
- state.setState(newState);
+ globalState.setState(newState);
};
// default to an active refresh interval if it's not conflicting with user-defined values
@@ -65,5 +68,9 @@ export const GlobalStateProvider: React.FC = ({
localState.save();
}
+ useUnmount(() => {
+ globalState.destroy();
+ });
+
return {children};
};
diff --git a/x-pack/plugins/observability/public/components/app/empty_sections/index.tsx b/x-pack/plugins/observability/public/components/app/empty_sections/index.tsx
index b2f0e9d1cb2b1..41fb539de2042 100644
--- a/x-pack/plugins/observability/public/components/app/empty_sections/index.tsx
+++ b/x-pack/plugins/observability/public/components/app/empty_sections/index.tsx
@@ -12,7 +12,7 @@ import { useKibana } from '@kbn/kibana-react-plugin/public';
import { ObservabilityAppServices } from '../../../application/types';
import { FETCH_STATUS } from '../../../hooks/use_fetcher';
import { useHasData } from '../../../hooks/use_has_data';
-import { getEmptySections } from '../../../pages/overview/empty_section';
+import { getEmptySections } from '../../../pages/overview';
import { EmptySection } from './empty_section';
export function EmptySections() {
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 2bf4c6bd04d4c..6ec620f535db7 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
@@ -23,7 +23,7 @@ import { useAlertIndexNames } from '../../../../hooks/use_alert_index_names';
import { useHasData } from '../../../../hooks/use_has_data';
import { usePluginContext } from '../../../../hooks/use_plugin_context';
import { getNoDataConfig } from '../../../../utils/no_data_config';
-import { LoadingObservability } from '../../../overview/loading_observability';
+import { LoadingObservability } from '../../../overview';
import {
Provider,
alertsPageStateContainer,
diff --git a/x-pack/plugins/observability/public/pages/cases/index.tsx b/x-pack/plugins/observability/public/pages/cases/index.tsx
index d0e5d82b3ad93..48b8eb2d9462c 100644
--- a/x-pack/plugins/observability/public/pages/cases/index.tsx
+++ b/x-pack/plugins/observability/public/pages/cases/index.tsx
@@ -14,7 +14,7 @@ import { CaseFeatureNoPermissions } from './feature_no_permissions';
import { useGetUserCasesPermissions } from '../../hooks/use_get_user_cases_permissions';
import { usePluginContext } from '../../hooks/use_plugin_context';
import { useHasData } from '../../hooks/use_has_data';
-import { LoadingObservability } from '../overview/loading_observability';
+import { LoadingObservability } from '../overview';
import { getNoDataConfig } from '../../utils/no_data_config';
import { ObservabilityAppServices } from '../../application/types';
diff --git a/x-pack/plugins/observability/public/pages/overview/data_sections.tsx b/x-pack/plugins/observability/public/pages/overview/components/data_sections.tsx
similarity index 71%
rename from x-pack/plugins/observability/public/pages/overview/data_sections.tsx
rename to x-pack/plugins/observability/public/pages/overview/components/data_sections.tsx
index 19827cd3eb459..2c38a9dc7bcb4 100644
--- a/x-pack/plugins/observability/public/pages/overview/data_sections.tsx
+++ b/x-pack/plugins/observability/public/pages/overview/components/data_sections.tsx
@@ -7,13 +7,13 @@
import { EuiFlexGroup, EuiFlexItem } from '@elastic/eui';
import React from 'react';
-import { APMSection } from '../../components/app/section/apm';
-import { LogsSection } from '../../components/app/section/logs';
-import { MetricsSection } from '../../components/app/section/metrics';
-import { UptimeSection } from '../../components/app/section/uptime';
-import { UXSection } from '../../components/app/section/ux';
-import { HasDataMap } from '../../context/has_data_context';
-import { BucketSize } from '.';
+import { APMSection } from '../../../components/app/section/apm';
+import { LogsSection } from '../../../components/app/section/logs';
+import { MetricsSection } from '../../../components/app/section/metrics';
+import { UptimeSection } from '../../../components/app/section/uptime';
+import { UXSection } from '../../../components/app/section/ux';
+import { HasDataMap } from '../../../context/has_data_context';
+import { BucketSize } from '../containers';
interface Props {
bucketSize: BucketSize;
diff --git a/x-pack/plugins/observability/public/pages/overview/empty_section.ts b/x-pack/plugins/observability/public/pages/overview/components/empty_section.ts
similarity index 97%
rename from x-pack/plugins/observability/public/pages/overview/empty_section.ts
rename to x-pack/plugins/observability/public/pages/overview/components/empty_section.ts
index 78db690cd5c0d..0d172e1a83cb4 100644
--- a/x-pack/plugins/observability/public/pages/overview/empty_section.ts
+++ b/x-pack/plugins/observability/public/pages/overview/components/empty_section.ts
@@ -7,8 +7,8 @@
import { i18n } from '@kbn/i18n';
import { HttpSetup } from '@kbn/core/public';
-import { ISection } from '../../typings/section';
-import { paths } from '../../config/paths';
+import { ISection } from '../../../typings/section';
+import { paths } from '../../../config/paths';
export const getEmptySections = ({ http }: { http: HttpSetup }): ISection[] => {
return [
diff --git a/x-pack/plugins/observability/public/pages/overview/components/index.ts b/x-pack/plugins/observability/public/pages/overview/components/index.ts
new file mode 100644
index 0000000000000..a3b9f0098e78f
--- /dev/null
+++ b/x-pack/plugins/observability/public/pages/overview/components/index.ts
@@ -0,0 +1,10 @@
+/*
+ * 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 './data_sections';
+export * from './loading_observability';
+export * from './empty_section';
diff --git a/x-pack/plugins/observability/public/pages/overview/loading_observability.tsx b/x-pack/plugins/observability/public/pages/overview/components/loading_observability.tsx
similarity index 88%
rename from x-pack/plugins/observability/public/pages/overview/loading_observability.tsx
rename to x-pack/plugins/observability/public/pages/overview/components/loading_observability.tsx
index 2ecd34eed52cb..dd0e19169874d 100644
--- a/x-pack/plugins/observability/public/pages/overview/loading_observability.tsx
+++ b/x-pack/plugins/observability/public/pages/overview/components/loading_observability.tsx
@@ -8,8 +8,8 @@
import { EuiFlexGroup, EuiFlexItem, EuiLoadingSpinner, EuiText } from '@elastic/eui';
import { i18n } from '@kbn/i18n';
import React from 'react';
-import { ObservabilityHeaderMenu } from '../../components/app/header';
-import { usePluginContext } from '../../hooks/use_plugin_context';
+import { ObservabilityHeaderMenu } from '../../../components/app/header';
+import { usePluginContext } from '../../../hooks/use_plugin_context';
export function LoadingObservability() {
const { ObservabilityPageTemplate } = usePluginContext();
diff --git a/x-pack/plugins/observability/public/pages/overview/containers/index.ts b/x-pack/plugins/observability/public/pages/overview/containers/index.ts
new file mode 100644
index 0000000000000..d547b4dcf916e
--- /dev/null
+++ b/x-pack/plugins/observability/public/pages/overview/containers/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 './overview_page';
diff --git a/x-pack/plugins/observability/public/pages/overview/containers/overview_page/constants.ts b/x-pack/plugins/observability/public/pages/overview/containers/overview_page/constants.ts
new file mode 100644
index 0000000000000..b9036ea4320af
--- /dev/null
+++ b/x-pack/plugins/observability/public/pages/overview/containers/overview_page/constants.ts
@@ -0,0 +1,11 @@
+/*
+ * 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 CAPABILITIES_KEYS = ['logs', 'infrastructure', 'apm', 'uptime'];
+
+export const ALERT_TABLE_STATE_STORAGE_KEY = 'xpack.observability.overview.alert.tableState';
+export const ALERTS_PER_PAGE = 10;
diff --git a/x-pack/plugins/observability/public/pages/overview/containers/overview_page/helpers/calculate_bucket_size.ts b/x-pack/plugins/observability/public/pages/overview/containers/overview_page/helpers/calculate_bucket_size.ts
new file mode 100644
index 0000000000000..5a2f8650baccc
--- /dev/null
+++ b/x-pack/plugins/observability/public/pages/overview/containers/overview_page/helpers/calculate_bucket_size.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 { Bucket, BucketSize } from '../types';
+import { getBucketSize } from '../../../../../utils/get_bucket_size';
+
+export function calculateBucketSize({ start, end }: Bucket): BucketSize {
+ if (start && end) {
+ return getBucketSize({ start, end, minInterval: '60s' });
+ }
+}
diff --git a/x-pack/plugins/observability/public/pages/overview/containers/overview_page/helpers/index.ts b/x-pack/plugins/observability/public/pages/overview/containers/overview_page/helpers/index.ts
new file mode 100644
index 0000000000000..565f52674214d
--- /dev/null
+++ b/x-pack/plugins/observability/public/pages/overview/containers/overview_page/helpers/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 { calculateBucketSize } from './calculate_bucket_size';
diff --git a/x-pack/plugins/observability/public/pages/overview/containers/overview_page/index.ts b/x-pack/plugins/observability/public/pages/overview/containers/overview_page/index.ts
new file mode 100644
index 0000000000000..699bbd51e2b36
--- /dev/null
+++ b/x-pack/plugins/observability/public/pages/overview/containers/overview_page/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; you may not use this file except in compliance with the Elastic License
+ * 2.0.
+ */
+
+export { OverviewPage } from './overview_page';
+export type { BucketSize } from './types';
diff --git a/x-pack/plugins/observability/public/pages/overview/index.tsx b/x-pack/plugins/observability/public/pages/overview/containers/overview_page/overview_page.tsx
similarity index 81%
rename from x-pack/plugins/observability/public/pages/overview/index.tsx
rename to x-pack/plugins/observability/public/pages/overview/containers/overview_page/overview_page.tsx
index 902dd3707d2f8..5a1dfdaa30252 100644
--- a/x-pack/plugins/observability/public/pages/overview/index.tsx
+++ b/x-pack/plugins/observability/public/pages/overview/containers/overview_page/overview_page.tsx
@@ -20,48 +20,38 @@ import {
} from '@elastic/eui';
import { i18n } from '@kbn/i18n';
import { FormattedMessage } from '@kbn/i18n-react';
-import React, { useMemo, useRef, useCallback, useState, useEffect } from 'react';
import { useKibana } from '@kbn/kibana-react-plugin/public';
import { Storage } from '@kbn/kibana-utils-plugin/public';
-import { observabilityFeatureId } from '../../../common';
-import { useTrackPageview, useUiTracker } from '../..';
-import { EmptySections } from '../../components/app/empty_sections';
-import { ObservabilityHeaderMenu } from '../../components/app/header';
-import { NewsFeed } from '../../components/app/news_feed';
-import { Resources } from '../../components/app/resources';
-import { DatePicker } from '../../components/shared/date_picker';
-import { useBreadcrumbs } from '../../hooks/use_breadcrumbs';
-import { useFetcher } from '../../hooks/use_fetcher';
-import { useHasData } from '../../hooks/use_has_data';
-import { usePluginContext } from '../../hooks/use_plugin_context';
-import { useAlertIndexNames } from '../../hooks/use_alert_index_names';
-import { getNewsFeed } from '../../services/get_news_feed';
-import { getBucketSize } from '../../utils/get_bucket_size';
-import { DataSections } from './data_sections';
-import { LoadingObservability } from './loading_observability';
-import { AlertsTableTGrid } from '../alerts/containers/alerts_table_t_grid/alerts_table_t_grid';
-import { SectionContainer } from '../../components/app/section';
-import { ObservabilityAppServices } from '../../application/types';
-import { useGetUserCasesPermissions } from '../../hooks/use_get_user_cases_permissions';
-import { paths } from '../../config';
-import { useDatePickerContext } from '../../hooks/use_date_picker_context';
-import { ObservabilityStatusProgress } from '../../components/app/observability_status/observability_status_progress';
-import { ObservabilityStatus } from '../../components/app/observability_status';
-import { useGuidedSetupProgress } from '../../hooks/use_guided_setup_progress';
-import { useObservabilityTourContext } from '../../components/shared/tour';
-
-export type BucketSize = ReturnType;
-
-const CAPABILITIES_KEYS = ['logs', 'infrastructure', 'apm', 'uptime'];
+import React, { useMemo, useRef, useCallback, useState, useEffect } from 'react';
-function calculateBucketSize({ start, end }: { start?: number; end?: number }) {
- if (start && end) {
- return getBucketSize({ start, end, minInterval: '60s' });
- }
-}
+import { calculateBucketSize } from './helpers';
+import { PageHeaderProps } from './types';
-const ALERT_TABLE_STATE_STORAGE_KEY = 'xpack.observability.overview.alert.tableState';
-const ALERTS_PER_PAGE = 10;
+import { EmptySections } from '../../../../components/app/empty_sections';
+import { observabilityFeatureId } from '../../../../../common';
+import { useTrackPageview, useUiTracker } from '../../../..';
+import { ObservabilityHeaderMenu } from '../../../../components/app/header';
+import { NewsFeed } from '../../../../components/app/news_feed';
+import { Resources } from '../../../../components/app/resources';
+import { DatePicker } from '../../../../components/shared/date_picker';
+import { useBreadcrumbs } from '../../../../hooks/use_breadcrumbs';
+import { useFetcher } from '../../../../hooks/use_fetcher';
+import { useHasData } from '../../../../hooks/use_has_data';
+import { usePluginContext } from '../../../../hooks/use_plugin_context';
+import { useAlertIndexNames } from '../../../../hooks/use_alert_index_names';
+import { getNewsFeed } from '../../../../services/get_news_feed';
+import { DataSections, LoadingObservability } from '../../components';
+import { AlertsTableTGrid } from '../../../alerts/containers/alerts_table_t_grid/alerts_table_t_grid';
+import { SectionContainer } from '../../../../components/app/section';
+import { ObservabilityAppServices } from '../../../../application/types';
+import { useGetUserCasesPermissions } from '../../../../hooks/use_get_user_cases_permissions';
+import { paths } from '../../../../config';
+import { useDatePickerContext } from '../../../../hooks/use_date_picker_context';
+import { ObservabilityStatusProgress } from '../../../../components/app/observability_status/observability_status_progress';
+import { ObservabilityStatus } from '../../../../components/app/observability_status';
+import { useGuidedSetupProgress } from '../../../../hooks/use_guided_setup_progress';
+import { useObservabilityTourContext } from '../../../../components/shared/tour';
+import { CAPABILITIES_KEYS, ALERT_TABLE_STATE_STORAGE_KEY, ALERTS_PER_PAGE } from './constants';
export function OverviewPage() {
const trackMetric = useUiTracker({ app: 'observability-overview' });
@@ -253,13 +243,6 @@ export function OverviewPage() {
);
}
-interface PageHeaderProps {
- showTour?: boolean;
- onTourDismiss: () => void;
- handleGuidedSetupClick: () => void;
- onTimeRangeRefresh: () => void;
-}
-
function PageHeader({
showTour = false,
onTourDismiss,
diff --git a/x-pack/plugins/observability/public/pages/overview/containers/overview_page/types.ts b/x-pack/plugins/observability/public/pages/overview/containers/overview_page/types.ts
new file mode 100644
index 0000000000000..654d6d0cb2486
--- /dev/null
+++ b/x-pack/plugins/observability/public/pages/overview/containers/overview_page/types.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.
+ */
+
+export interface Bucket {
+ start?: number;
+ end?: number;
+}
+export type BucketSize = { bucketSize: number; intervalString: string } | undefined;
+
+export interface PageHeaderProps {
+ showTour?: boolean;
+ onTourDismiss: () => void;
+ handleGuidedSetupClick: () => void;
+ onTimeRangeRefresh: () => void;
+}
diff --git a/x-pack/plugins/observability/public/pages/overview/index.ts b/x-pack/plugins/observability/public/pages/overview/index.ts
new file mode 100644
index 0000000000000..525f3441c4470
--- /dev/null
+++ b/x-pack/plugins/observability/public/pages/overview/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; you may not use this file except in compliance with the Elastic License
+ * 2.0.
+ */
+
+export * from './components';
+export * from './containers';
diff --git a/x-pack/plugins/osquery/cypress/integration/all/live_query.spec.ts b/x-pack/plugins/osquery/cypress/integration/all/live_query.spec.ts
index c332e3dae5087..b04dff5d39ab3 100644
--- a/x-pack/plugins/osquery/cypress/integration/all/live_query.spec.ts
+++ b/x-pack/plugins/osquery/cypress/integration/all/live_query.spec.ts
@@ -105,7 +105,7 @@ describe('ALL - Live Query', () => {
selectAllAgents();
cy.react('SavedQueriesDropdown').type('NOMAPPING{downArrow}{enter}');
// cy.getReact('SavedQueriesDropdown').getCurrentState().should('have.length', 1); // TODO do we need it?
- inputQuery('{selectall}{backspace}{selectall}{backspace}select * from users');
+ inputQuery('{selectall}{backspace}select * from users;');
cy.wait(1000);
submitQuery();
checkResults();
@@ -115,15 +115,14 @@ describe('ALL - Live Query', () => {
.should('be.visible')
.click();
- cy.react('ReactAce', { props: { value: 'select * from users' } }).should('exist');
+ cy.react('ReactAce', { props: { value: 'select * from users;' } }).should('exist');
});
it('should run live pack', () => {
cy.contains('New live query').click();
cy.contains('Run a set of queries in a pack.').click();
cy.get(LIVE_QUERY_EDITOR).should('not.exist');
- cy.getBySel('select-live-pack').click();
- cy.contains('Example').click();
+ cy.getBySel('select-live-pack').click().type('Example{downArrow}{enter}');
cy.contains('This table contains 3 rows.');
cy.contains('system_memory_linux_elastic');
cy.contains('system_info_elastic');
diff --git a/x-pack/plugins/osquery/cypress/integration/all/packs.spec.ts b/x-pack/plugins/osquery/cypress/integration/all/packs.spec.ts
index 64620cf3cc08c..b53651afa7157 100644
--- a/x-pack/plugins/osquery/cypress/integration/all/packs.spec.ts
+++ b/x-pack/plugins/osquery/cypress/integration/all/packs.spec.ts
@@ -19,6 +19,7 @@ import { addIntegration, closeModalIfVisible } from '../../tasks/integrations';
import { DEFAULT_POLICY } from '../../screens/fleet';
import { getSavedQueriesDropdown } from '../../screens/live_query';
import { ROLES } from '../../test';
+import { getRandomInt } from '../../tasks/helpers';
describe('ALL - Packs', () => {
const integration = 'Osquery Manager';
@@ -251,7 +252,8 @@ describe('ALL - Packs', () => {
beforeEach(() => {
login();
});
- const AGENT_NAME = 'PackTest2';
+ const randomNumber = getRandomInt();
+ const AGENT_NAME = `PackTest${randomNumber}`;
const REMOVING_PACK = 'removing-pack';
it('add integration', () => {
cy.visit(FLEET_AGENT_POLICIES);
@@ -272,7 +274,7 @@ describe('ALL - Packs', () => {
findAndClickButton('Save pack');
cy.getBySel('toastCloseButton').click();
- cy.contains(REMOVING_PACK).click();
+ cy.react('ScheduledQueryNameComponent', { props: { name: REMOVING_PACK } }).click();
cy.contains(`${REMOVING_PACK} details`).should('exist');
findAndClickButton('Edit');
cy.react('EuiComboBoxInput', { props: { value: AGENT_NAME } }).should('exist');
diff --git a/x-pack/plugins/osquery/cypress/integration/all/saved_queries.spec.ts b/x-pack/plugins/osquery/cypress/integration/all/saved_queries.spec.ts
index 18167506fc75c..e4d76ce9438eb 100644
--- a/x-pack/plugins/osquery/cypress/integration/all/saved_queries.spec.ts
+++ b/x-pack/plugins/osquery/cypress/integration/all/saved_queries.spec.ts
@@ -8,17 +8,18 @@
import { navigateTo } from '../../tasks/navigation';
import { login } from '../../tasks/login';
-import { getSavedQueriesComplexTest } from '../../tasks/saved_queries';
import { ROLES } from '../../test';
-const SAVED_QUERY_ID = 'Saved-Query-Id';
-const SAVED_QUERY_DESCRIPTION = 'Test saved query description';
-
describe('ALL - Saved queries', () => {
+ // const randomNumber = getRandomInt();
+ // const SAVED_QUERY_ID = `Saved-Query-Id-${randomNumber}`;
+ // const SAVED_QUERY_DESCRIPTION = `Test saved query description ${randomNumber}`;
+
beforeEach(() => {
login(ROLES.soc_manager);
navigateTo('/app/osquery');
});
- getSavedQueriesComplexTest(SAVED_QUERY_ID, SAVED_QUERY_DESCRIPTION);
+ // TODO usnkip after FF
+ // getSavedQueriesComplexTest(SAVED_QUERY_ID, SAVED_QUERY_DESCRIPTION);
});
diff --git a/x-pack/plugins/osquery/cypress/integration/roles/t1_analyst.spec.ts b/x-pack/plugins/osquery/cypress/integration/roles/t1_analyst.spec.ts
index d236555091b3f..8cd90d200bca7 100644
--- a/x-pack/plugins/osquery/cypress/integration/roles/t1_analyst.spec.ts
+++ b/x-pack/plugins/osquery/cypress/integration/roles/t1_analyst.spec.ts
@@ -55,7 +55,8 @@ describe('T1 Analyst - READ + runSavedQueries ', () => {
submitQuery();
checkResults();
});
- it('should be able to use saved query in a new query', () => {
+ // TODO UNSKIP AFTER FF
+ it.skip('should be able to use saved query in a new query', () => {
navigateTo('/app/osquery/live_queries');
cy.waitForReact(1000);
cy.contains('New live query').should('not.be.disabled').click();
diff --git a/x-pack/plugins/osquery/cypress/integration/roles/t2_analyst.spec.ts b/x-pack/plugins/osquery/cypress/integration/roles/t2_analyst.spec.ts
index 63a0eb5d1619d..423977675ed0d 100644
--- a/x-pack/plugins/osquery/cypress/integration/roles/t2_analyst.spec.ts
+++ b/x-pack/plugins/osquery/cypress/integration/roles/t2_analyst.spec.ts
@@ -17,12 +17,13 @@ import {
typeInOsqueryFieldInput,
} from '../../tasks/live_query';
import { ArchiverMethod, runKbnArchiverScript } from '../../tasks/archiver';
-import { getSavedQueriesComplexTest } from '../../tasks/saved_queries';
describe('T2 Analyst - READ + Write Live/Saved + runSavedQueries ', () => {
const SAVED_QUERY_ID = 'Saved-Query-Id';
- const NEW_SAVED_QUERY_ID = 'Saved-Query-Id-T2';
- const NEW_SAVED_QUERY_DESCRIPTION = 'Test saved query description T2';
+ // const randomNumber = getRandomInt();
+ //
+ // const NEW_SAVED_QUERY_ID = `Saved-Query-Id-${randomNumber}`;
+ // const NEW_SAVED_QUERY_DESCRIPTION = `Test saved query description ${randomNumber}`;
beforeEach(() => {
login(ROLES.t2_analyst);
navigateTo('/app/osquery');
@@ -35,7 +36,8 @@ describe('T2 Analyst - READ + Write Live/Saved + runSavedQueries ', () => {
runKbnArchiverScript(ArchiverMethod.UNLOAD, 'saved_query');
});
- getSavedQueriesComplexTest(NEW_SAVED_QUERY_ID, NEW_SAVED_QUERY_DESCRIPTION);
+ // TODO unskip after FF
+ // getSavedQueriesComplexTest(NEW_SAVED_QUERY_ID, NEW_SAVED_QUERY_DESCRIPTION);
it('should not be able to add nor edit packs', () => {
const PACK_NAME = 'removing-pack';
diff --git a/x-pack/plugins/osquery/cypress/tasks/helpers.ts b/x-pack/plugins/osquery/cypress/tasks/helpers.ts
new file mode 100644
index 0000000000000..14818a637333e
--- /dev/null
+++ b/x-pack/plugins/osquery/cypress/tasks/helpers.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 getRandomInt = () => Math.floor(Math.random() * 100);
diff --git a/x-pack/plugins/osquery/cypress/tasks/saved_queries.ts b/x-pack/plugins/osquery/cypress/tasks/saved_queries.ts
index d288584b6a169..4de712bd2f55a 100644
--- a/x-pack/plugins/osquery/cypress/tasks/saved_queries.ts
+++ b/x-pack/plugins/osquery/cypress/tasks/saved_queries.ts
@@ -39,16 +39,21 @@ export const getSavedQueriesComplexTest = (savedQueryId: string, savedQueryDescr
cy.contains('Exit fullscreen').should('exist');
// hidden columns
+ cy.contains('columns hidden').should('not.exist');
cy.react('EuiDataGridHeaderCellWrapper', { props: { id: 'osquery.cmdline' } }).click();
cy.contains(/Hide column$/).click();
+ cy.react('EuiDataGridHeaderCellWrapper', {
+ props: { id: 'osquery.cwd' },
+ }).click();
+ cy.contains(/Hide column$/).click();
cy.react('EuiDataGridHeaderCellWrapper', {
props: { id: 'osquery.disk_bytes_written.number' },
}).click();
cy.contains(/Hide column$/).click();
- cy.contains('2 columns hidden').should('exist');
+ cy.contains('columns hidden').should('exist');
// change pagination
cy.getBySel('pagination-button-next').click().wait(500).click();
- cy.contains('2 columns hidden').should('exist');
+ cy.contains('columns hidden').should('exist');
cy.getBySel(RESULTS_TABLE_BUTTON).trigger('mouseover');
cy.contains(/Enter fullscreen$/).should('not.exist');
@@ -60,10 +65,14 @@ export const getSavedQueriesComplexTest = (savedQueryId: string, savedQueryDescr
props: { id: 'osquery.egid' },
}).click();
cy.contains(/Sort A-Z$/).click();
- cy.contains('2 columns hidden').should('exist');
+ cy.contains('columns hidden').should('exist');
cy.getBySel(RESULTS_TABLE_BUTTON).trigger('mouseover');
cy.contains(/Enter fullscreen$/).should('exist');
+ // visit Status results
+ cy.react('EuiTab', { props: { id: 'status' } }).click();
+ cy.react('EuiTableRow').should('have.lengthOf', 1);
+
// save new query
cy.contains('Exit full screen').should('not.exist');
cy.contains('Save for later').click();
@@ -71,11 +80,7 @@ export const getSavedQueriesComplexTest = (savedQueryId: string, savedQueryDescr
findFormFieldByRowsLabelAndType('ID', savedQueryId);
findFormFieldByRowsLabelAndType('Description (optional)', savedQueryDescription);
cy.react('EuiButtonDisplay').contains('Save').click();
-
- // visit Status results
- cy.react('EuiTab', { props: { id: 'status' } }).click();
- cy.react('EuiTableRow').should('have.lengthOf', 1);
- // cy.contains('Successful').siblings().contains(1);
+ cy.contains('Successfully saved');
// play saved query
cy.contains('Saved queries').click();
diff --git a/x-pack/plugins/security_solution/common/detection_engine/schemas/common/schemas.ts b/x-pack/plugins/security_solution/common/detection_engine/schemas/common/schemas.ts
index c0975925d480c..aa07dfcbba8b2 100644
--- a/x-pack/plugins/security_solution/common/detection_engine/schemas/common/schemas.ts
+++ b/x-pack/plugins/security_solution/common/detection_engine/schemas/common/schemas.ts
@@ -8,7 +8,6 @@
/* eslint-disable @typescript-eslint/naming-convention */
import {
- enumeration,
IsoDateString,
NonEmptyString,
PositiveInteger,
@@ -359,75 +358,3 @@ export const privilege = t.type({
});
export type Privilege = t.TypeOf;
-
-export enum BulkAction {
- 'enable' = 'enable',
- 'disable' = 'disable',
- 'export' = 'export',
- 'delete' = 'delete',
- 'duplicate' = 'duplicate',
- 'edit' = 'edit',
-}
-
-export const bulkAction = enumeration('BulkAction', BulkAction);
-
-export enum BulkActionEditType {
- 'add_tags' = 'add_tags',
- 'delete_tags' = 'delete_tags',
- 'set_tags' = 'set_tags',
- 'add_index_patterns' = 'add_index_patterns',
- 'delete_index_patterns' = 'delete_index_patterns',
- 'set_index_patterns' = 'set_index_patterns',
- 'set_timeline' = 'set_timeline',
-}
-
-const bulkActionEditPayloadTags = t.type({
- type: t.union([
- t.literal(BulkActionEditType.add_tags),
- t.literal(BulkActionEditType.delete_tags),
- t.literal(BulkActionEditType.set_tags),
- ]),
- value: tags,
-});
-
-export type BulkActionEditPayloadTags = t.TypeOf;
-
-const bulkActionEditPayloadIndexPatterns = t.intersection([
- t.type({
- type: t.union([
- t.literal(BulkActionEditType.add_index_patterns),
- t.literal(BulkActionEditType.delete_index_patterns),
- t.literal(BulkActionEditType.set_index_patterns),
- ]),
- value: index,
- }),
- t.exact(t.partial({ overwrite_data_views: t.boolean })),
-]);
-
-export type BulkActionEditPayloadIndexPatterns = t.TypeOf<
- typeof bulkActionEditPayloadIndexPatterns
->;
-
-const bulkActionEditPayloadTimeline = t.type({
- type: t.literal(BulkActionEditType.set_timeline),
- value: t.type({
- timeline_id,
- timeline_title,
- }),
-});
-
-export type BulkActionEditPayloadTimeline = t.TypeOf;
-
-export const bulkActionEditPayload = t.union([
- bulkActionEditPayloadTags,
- bulkActionEditPayloadIndexPatterns,
- bulkActionEditPayloadTimeline,
-]);
-
-export type BulkActionEditPayload = t.TypeOf;
-
-export type BulkActionEditForRuleAttributes = BulkActionEditPayloadTags;
-
-export type BulkActionEditForRuleParams =
- | BulkActionEditPayloadIndexPatterns
- | BulkActionEditPayloadTimeline;
diff --git a/x-pack/plugins/security_solution/common/detection_engine/schemas/request/perform_bulk_action_schema.mock.ts b/x-pack/plugins/security_solution/common/detection_engine/schemas/request/perform_bulk_action_schema.mock.ts
index b3988568a4765..1768acc8dfbfa 100644
--- a/x-pack/plugins/security_solution/common/detection_engine/schemas/request/perform_bulk_action_schema.mock.ts
+++ b/x-pack/plugins/security_solution/common/detection_engine/schemas/request/perform_bulk_action_schema.mock.ts
@@ -5,7 +5,7 @@
* 2.0.
*/
-import { BulkAction, BulkActionEditType } from '../common/schemas';
+import { BulkAction, BulkActionEditType } from './perform_bulk_action_schema';
import type { PerformBulkActionSchema } from './perform_bulk_action_schema';
export const getPerformBulkActionSchemaMock = (): PerformBulkActionSchema => ({
diff --git a/x-pack/plugins/security_solution/common/detection_engine/schemas/request/perform_bulk_action_schema.test.ts b/x-pack/plugins/security_solution/common/detection_engine/schemas/request/perform_bulk_action_schema.test.ts
index a1f6122a2ef35..f6de8a29cc90d 100644
--- a/x-pack/plugins/security_solution/common/detection_engine/schemas/request/perform_bulk_action_schema.test.ts
+++ b/x-pack/plugins/security_solution/common/detection_engine/schemas/request/perform_bulk_action_schema.test.ts
@@ -6,10 +6,13 @@
*/
import type { PerformBulkActionSchema } from './perform_bulk_action_schema';
-import { performBulkActionSchema } from './perform_bulk_action_schema';
+import {
+ performBulkActionSchema,
+ BulkAction,
+ BulkActionEditType,
+} from './perform_bulk_action_schema';
import { exactCheck, foldLeftRight, getPaths } from '@kbn/securitysolution-io-ts-utils';
import { left } from 'fp-ts/lib/Either';
-import { BulkAction, BulkActionEditType } from '../common/schemas';
const retrieveValidationMessage = (payload: unknown) => {
const decoded = performBulkActionSchema.decode(payload);
@@ -343,12 +346,12 @@ describe('perform_bulk_action_schema', () => {
const message = retrieveValidationMessage(payload);
- expect(getPaths(left(message.errors))).toEqual([
- 'Invalid value "edit" supplied to "action"',
- 'Invalid value "set_timeline" supplied to "edit,type"',
- 'Invalid value "{"timeline_title":"Test timeline title"}" supplied to "edit,value"',
- 'Invalid value "undefined" supplied to "edit,value,timeline_id"',
- ]);
+ expect(getPaths(left(message.errors))).toEqual(
+ expect.arrayContaining([
+ 'Invalid value "{"timeline_title":"Test timeline title"}" supplied to "edit,value"',
+ 'Invalid value "undefined" supplied to "edit,value,timeline_id"',
+ ])
+ );
expect(message.schema).toEqual({});
});
@@ -373,5 +376,163 @@ describe('perform_bulk_action_schema', () => {
expect(message.schema).toEqual(payload);
});
});
+
+ describe('rule actions', () => {
+ test('invalid request: invalid rule actions payload', () => {
+ const payload = {
+ query: 'name: test',
+ action: BulkAction.edit,
+ [BulkAction.edit]: [{ type: BulkActionEditType.add_rule_actions, value: [] }],
+ };
+
+ const message = retrieveValidationMessage(payload);
+
+ expect(getPaths(left(message.errors))).toEqual(
+ expect.arrayContaining(['Invalid value "[]" supplied to "edit,value"'])
+ );
+ expect(message.schema).toEqual({});
+ });
+
+ test('invalid request: missing throttle in payload', () => {
+ const payload = {
+ query: 'name: test',
+ action: BulkAction.edit,
+ [BulkAction.edit]: [
+ {
+ type: BulkActionEditType.add_rule_actions,
+ value: {
+ actions: [],
+ },
+ },
+ ],
+ };
+
+ const message = retrieveValidationMessage(payload);
+
+ expect(getPaths(left(message.errors))).toEqual(
+ expect.arrayContaining(['Invalid value "undefined" supplied to "edit,value,throttle"'])
+ );
+ expect(message.schema).toEqual({});
+ });
+
+ test('invalid request: missing actions in payload', () => {
+ const payload = {
+ query: 'name: test',
+ action: BulkAction.edit,
+ [BulkAction.edit]: [
+ {
+ type: BulkActionEditType.add_rule_actions,
+ value: {
+ throttle: '1h',
+ },
+ },
+ ],
+ };
+
+ const message = retrieveValidationMessage(payload);
+
+ expect(getPaths(left(message.errors))).toEqual(
+ expect.arrayContaining(['Invalid value "undefined" supplied to "edit,value,actions"'])
+ );
+ expect(message.schema).toEqual({});
+ });
+
+ test('invalid request: invalid action_type_id property in actions array', () => {
+ const payload = {
+ query: 'name: test',
+ action: BulkAction.edit,
+ [BulkAction.edit]: [
+ {
+ type: BulkActionEditType.add_rule_actions,
+ value: {
+ throttle: '1h',
+ actions: [
+ {
+ action_type_id: '.webhook',
+ group: 'default',
+ id: '458a50e0-1a28-11ed-9098-47fd8e1f3345',
+ params: {
+ body: {
+ rule_id: '{{rule.id}}',
+ },
+ },
+ },
+ ],
+ },
+ },
+ ],
+ };
+
+ const message = retrieveValidationMessage(payload);
+ expect(getPaths(left(message.errors))).toEqual(
+ expect.arrayContaining(['invalid keys "action_type_id"'])
+ );
+ expect(message.schema).toEqual({});
+ });
+
+ test('valid request: add_rule_actions edit action', () => {
+ const payload: PerformBulkActionSchema = {
+ query: 'name: test',
+ action: BulkAction.edit,
+ [BulkAction.edit]: [
+ {
+ type: BulkActionEditType.add_rule_actions,
+ value: {
+ throttle: '1h',
+ actions: [
+ {
+ group: 'default',
+ id: '458a50e0-1a28-11ed-9098-47fd8e1f3345',
+ params: {
+ body: {
+ rule_id: '{{rule.id}}',
+ },
+ },
+ },
+ ],
+ },
+ },
+ ],
+ };
+
+ const message = retrieveValidationMessage(payload);
+
+ expect(getPaths(left(message.errors))).toEqual([]);
+ expect(message.schema).toEqual(payload);
+ });
+
+ test('valid request: set_rule_actions edit action', () => {
+ const payload: PerformBulkActionSchema = {
+ query: 'name: test',
+ action: BulkAction.edit,
+ [BulkAction.edit]: [
+ {
+ type: BulkActionEditType.set_rule_actions,
+ value: {
+ throttle: '1h',
+ actions: [
+ {
+ group: 'default',
+ id: '458a50e0-1a28-11ed-9098-47fd8e1f3345',
+ params: {
+ documents: [
+ {
+ rule_id: '{{rule.id}}',
+ },
+ ],
+ },
+ },
+ ],
+ },
+ },
+ ],
+ };
+
+ const message = retrieveValidationMessage(payload);
+
+ expect(getPaths(left(message.errors))).toEqual([]);
+ expect(message.schema).toEqual(payload);
+ });
+ });
});
});
diff --git a/x-pack/plugins/security_solution/common/detection_engine/schemas/request/perform_bulk_action_schema.ts b/x-pack/plugins/security_solution/common/detection_engine/schemas/request/perform_bulk_action_schema.ts
index fa33e75e236fd..58675bf3c0d99 100644
--- a/x-pack/plugins/security_solution/common/detection_engine/schemas/request/perform_bulk_action_schema.ts
+++ b/x-pack/plugins/security_solution/common/detection_engine/schemas/request/perform_bulk_action_schema.ts
@@ -6,8 +6,124 @@
*/
import * as t from 'io-ts';
-import { NonEmptyArray } from '@kbn/securitysolution-io-ts-types';
-import { BulkAction, queryOrUndefined, bulkActionEditPayload } from '../common/schemas';
+import { NonEmptyArray, enumeration } from '@kbn/securitysolution-io-ts-types';
+
+import {
+ throttle,
+ action_group as actionGroup,
+ action_params as actionParams,
+ action_id as actionId,
+} from '@kbn/securitysolution-io-ts-alerting-types';
+
+import { queryOrUndefined, tags, index, timeline_id, timeline_title } from '../common/schemas';
+
+export enum BulkAction {
+ 'enable' = 'enable',
+ 'disable' = 'disable',
+ 'export' = 'export',
+ 'delete' = 'delete',
+ 'duplicate' = 'duplicate',
+ 'edit' = 'edit',
+}
+
+export const bulkAction = enumeration('BulkAction', BulkAction);
+
+export enum BulkActionEditType {
+ 'add_tags' = 'add_tags',
+ 'delete_tags' = 'delete_tags',
+ 'set_tags' = 'set_tags',
+ 'add_index_patterns' = 'add_index_patterns',
+ 'delete_index_patterns' = 'delete_index_patterns',
+ 'set_index_patterns' = 'set_index_patterns',
+ 'set_timeline' = 'set_timeline',
+ 'add_rule_actions' = 'add_rule_actions',
+ 'set_rule_actions' = 'set_rule_actions',
+}
+
+const bulkActionEditPayloadTags = t.type({
+ type: t.union([
+ t.literal(BulkActionEditType.add_tags),
+ t.literal(BulkActionEditType.delete_tags),
+ t.literal(BulkActionEditType.set_tags),
+ ]),
+ value: tags,
+});
+
+export type BulkActionEditPayloadTags = t.TypeOf;
+
+const bulkActionEditPayloadIndexPatterns = t.intersection([
+ t.type({
+ type: t.union([
+ t.literal(BulkActionEditType.add_index_patterns),
+ t.literal(BulkActionEditType.delete_index_patterns),
+ t.literal(BulkActionEditType.set_index_patterns),
+ ]),
+ value: index,
+ }),
+ t.exact(t.partial({ overwrite_data_views: t.boolean })),
+]);
+
+export type BulkActionEditPayloadIndexPatterns = t.TypeOf<
+ typeof bulkActionEditPayloadIndexPatterns
+>;
+
+const bulkActionEditPayloadTimeline = t.type({
+ type: t.literal(BulkActionEditType.set_timeline),
+ value: t.type({
+ timeline_id,
+ timeline_title,
+ }),
+});
+
+export type BulkActionEditPayloadTimeline = t.TypeOf;
+
+/**
+ * per rulesClient.bulkEdit rules actions operation contract (x-pack/plugins/alerting/server/rules_client/rules_client.ts)
+ * normalized rule action object is expected (NormalizedAlertAction) as value for the edit operation
+ */
+const normalizedRuleAction = t.exact(
+ t.type({
+ group: actionGroup,
+ id: actionId,
+ params: actionParams,
+ })
+);
+
+const bulkActionEditPayloadRuleActions = t.type({
+ type: t.union([
+ t.literal(BulkActionEditType.add_rule_actions),
+ t.literal(BulkActionEditType.set_rule_actions),
+ ]),
+ value: t.type({
+ throttle,
+ actions: t.array(normalizedRuleAction),
+ }),
+});
+
+export type BulkActionEditPayloadRuleActions = t.TypeOf;
+
+export const bulkActionEditPayload = t.union([
+ bulkActionEditPayloadTags,
+ bulkActionEditPayloadIndexPatterns,
+ bulkActionEditPayloadTimeline,
+ bulkActionEditPayloadRuleActions,
+]);
+
+export type BulkActionEditPayload = t.TypeOf;
+
+/**
+ * actions that modify rules attributes
+ */
+export type BulkActionEditForRuleAttributes =
+ | BulkActionEditPayloadTags
+ | BulkActionEditPayloadRuleActions;
+
+/**
+ * actions that modify rules params
+ */
+export type BulkActionEditForRuleParams =
+ | BulkActionEditPayloadIndexPatterns
+ | BulkActionEditPayloadTimeline;
export const performBulkActionSchema = t.intersection([
t.exact(
diff --git a/x-pack/plugins/security_solution/public/detections/components/rules/rule_actions_overflow/index.tsx b/x-pack/plugins/security_solution/public/detections/components/rules/rule_actions_overflow/index.tsx
index b8e423827edce..beb8e8365d74e 100644
--- a/x-pack/plugins/security_solution/public/detections/components/rules/rule_actions_overflow/index.tsx
+++ b/x-pack/plugins/security_solution/public/detections/components/rules/rule_actions_overflow/index.tsx
@@ -16,7 +16,7 @@ import { noop } from 'lodash';
import React, { useCallback, useMemo } from 'react';
import styled from 'styled-components';
import { APP_UI_ID, SecurityPageName } from '../../../../../common/constants';
-import { BulkAction } from '../../../../../common/detection_engine/schemas/common';
+import { BulkAction } from '../../../../../common/detection_engine/schemas/request/perform_bulk_action_schema';
import { getRulesUrl } from '../../../../common/components/link_to/redirect_to_detection_engine';
import { useAppToasts } from '../../../../common/hooks/use_app_toasts';
import { useBoolState } from '../../../../common/hooks/use_bool_state';
diff --git a/x-pack/plugins/security_solution/public/detections/components/rules/rule_switch/index.tsx b/x-pack/plugins/security_solution/public/detections/components/rules/rule_switch/index.tsx
index 574f4ec166193..6c924a68da4a1 100644
--- a/x-pack/plugins/security_solution/public/detections/components/rules/rule_switch/index.tsx
+++ b/x-pack/plugins/security_solution/public/detections/components/rules/rule_switch/index.tsx
@@ -10,7 +10,7 @@ import { EuiFlexGroup, EuiFlexItem, EuiLoadingSpinner, EuiSwitch } from '@elasti
import { noop } from 'lodash';
import React, { useCallback, useMemo, useState } from 'react';
import styled from 'styled-components';
-import { BulkAction } from '../../../../../common/detection_engine/schemas/common';
+import { BulkAction } from '../../../../../common/detection_engine/schemas/request/perform_bulk_action_schema';
import { useAppToasts } from '../../../../common/hooks/use_app_toasts';
import { SINGLE_RULE_ACTIONS } from '../../../../common/lib/apm/user_actions';
import { useStartTransaction } from '../../../../common/lib/apm/use_start_transaction';
diff --git a/x-pack/plugins/security_solution/public/detections/components/rules/step_rule_actions/get_schema.ts b/x-pack/plugins/security_solution/public/detections/components/rules/step_rule_actions/get_schema.ts
new file mode 100644
index 0000000000000..57a7dd50a370e
--- /dev/null
+++ b/x-pack/plugins/security_solution/public/detections/components/rules/step_rule_actions/get_schema.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 { i18n } from '@kbn/i18n';
+
+import type { ActionTypeRegistryContract } from '@kbn/triggers-actions-ui-plugin/public';
+import { validateRuleActionsField } from '../../../containers/detection_engine/rules/validate_rule_actions_field';
+
+import type { FormSchema } from '../../../../shared_imports';
+import type { ActionsStepRule } from '../../../pages/detection_engine/rules/types';
+
+export const getSchema = ({
+ actionTypeRegistry,
+}: {
+ actionTypeRegistry: ActionTypeRegistryContract;
+}): FormSchema => ({
+ actions: {
+ validations: [
+ {
+ validator: validateRuleActionsField(actionTypeRegistry),
+ },
+ ],
+ },
+ enabled: {},
+ kibanaSiemAppUrl: {},
+ throttle: {
+ label: i18n.translate(
+ 'xpack.securitySolution.detectionEngine.createRule.stepRuleActions.fieldThrottleLabel',
+ {
+ defaultMessage: 'Actions frequency',
+ }
+ ),
+ helpText: i18n.translate(
+ 'xpack.securitySolution.detectionEngine.createRule.stepRuleActions.fieldThrottleHelpText',
+ {
+ defaultMessage:
+ 'Select when automated actions should be performed if a rule evaluates as true.',
+ }
+ ),
+ },
+});
diff --git a/x-pack/plugins/security_solution/public/detections/components/rules/step_rule_actions/index.tsx b/x-pack/plugins/security_solution/public/detections/components/rules/step_rule_actions/index.tsx
index d8264794f1df8..b967304d57349 100644
--- a/x-pack/plugins/security_solution/public/detections/components/rules/step_rule_actions/index.tsx
+++ b/x-pack/plugins/security_solution/public/detections/components/rules/step_rule_actions/index.tsx
@@ -31,7 +31,7 @@ import {
} from '../throttle_select_field';
import { RuleActionsField } from '../rule_actions_field';
import { useKibana } from '../../../../common/lib/kibana';
-import { getSchema } from './schema';
+import { getSchema } from './get_schema';
import * as I18n from './translations';
import { APP_UI_ID } from '../../../../../common/constants';
import { useManageCaseAction } from './use_manage_case_action';
diff --git a/x-pack/plugins/security_solution/public/detections/components/rules/step_rule_actions/translations.tsx b/x-pack/plugins/security_solution/public/detections/components/rules/step_rule_actions/translations.tsx
index f0d3d7b7d351e..d467c3af05f8f 100644
--- a/x-pack/plugins/security_solution/public/detections/components/rules/step_rule_actions/translations.tsx
+++ b/x-pack/plugins/security_solution/public/detections/components/rules/step_rule_actions/translations.tsx
@@ -6,7 +6,6 @@
*/
import { i18n } from '@kbn/i18n';
-import { startCase } from 'lodash/fp';
export const COMPLETE_WITHOUT_ENABLING = i18n.translate(
'xpack.securitySolution.detectionEngine.createRule.stepScheduleRule.completeWithoutEnablingTitle',
@@ -29,14 +28,3 @@ export const NO_ACTIONS_READ_PERMISSIONS = i18n.translate(
'Cannot create rule actions. You do not have "Read" permissions for the "Actions" plugin.',
}
);
-
-export const INVALID_MUSTACHE_TEMPLATE = (paramKey: string) =>
- i18n.translate(
- 'xpack.securitySolution.detectionEngine.createRule.stepRuleActions.invalidMustacheTemplateErrorMessage',
- {
- defaultMessage: '{key} is not valid mustache template',
- values: {
- key: startCase(paramKey),
- },
- }
- );
diff --git a/x-pack/plugins/security_solution/public/detections/containers/detection_engine/rules/api.ts b/x-pack/plugins/security_solution/public/detections/containers/detection_engine/rules/api.ts
index 0e2f238aa527e..876a3a0a469a8 100644
--- a/x-pack/plugins/security_solution/public/detections/containers/detection_engine/rules/api.ts
+++ b/x-pack/plugins/security_solution/public/detections/containers/detection_engine/rules/api.ts
@@ -18,7 +18,7 @@ import {
DETECTION_ENGINE_INSTALLED_INTEGRATIONS_URL,
DETECTION_ENGINE_RULES_URL_FIND,
} from '../../../../../common/constants';
-import type { BulkAction } from '../../../../../common/detection_engine/schemas/common';
+import type { BulkAction } from '../../../../../common/detection_engine/schemas/request/perform_bulk_action_schema';
import type {
FullResponseSchema,
PreviewResponse,
diff --git a/x-pack/plugins/security_solution/public/detections/containers/detection_engine/rules/types.ts b/x-pack/plugins/security_solution/public/detections/containers/detection_engine/rules/types.ts
index eaf9b3288dc2d..45c89c307de4e 100644
--- a/x-pack/plugins/security_solution/public/detections/containers/detection_engine/rules/types.ts
+++ b/x-pack/plugins/security_solution/public/detections/containers/detection_engine/rules/types.ts
@@ -25,11 +25,11 @@ import {
import { RuleExecutionSummary } from '../../../../../common/detection_engine/rule_monitoring';
+import type { SortOrder } from '../../../../../common/detection_engine/schemas/common';
import type {
- SortOrder,
- BulkAction,
BulkActionEditPayload,
-} from '../../../../../common/detection_engine/schemas/common';
+ BulkAction,
+} from '../../../../../common/detection_engine/schemas/request/perform_bulk_action_schema';
import {
alias_purpose as savedObjectResolveAliasPurpose,
outcome as savedObjectResolveOutcome,
diff --git a/x-pack/plugins/security_solution/public/detections/containers/detection_engine/rules/validate_rule_actions_field/index.tsx b/x-pack/plugins/security_solution/public/detections/containers/detection_engine/rules/validate_rule_actions_field/index.tsx
new file mode 100644
index 0000000000000..22d05080a408b
--- /dev/null
+++ b/x-pack/plugins/security_solution/public/detections/containers/detection_engine/rules/validate_rule_actions_field/index.tsx
@@ -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 { validateRuleActionsField } from './validate_rule_actions_field';
diff --git a/x-pack/plugins/security_solution/public/detections/containers/detection_engine/rules/validate_rule_actions_field/translations.ts b/x-pack/plugins/security_solution/public/detections/containers/detection_engine/rules/validate_rule_actions_field/translations.ts
new file mode 100644
index 0000000000000..6540f7071ccd6
--- /dev/null
+++ b/x-pack/plugins/security_solution/public/detections/containers/detection_engine/rules/validate_rule_actions_field/translations.ts
@@ -0,0 +1,20 @@
+/*
+ * 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 { startCase } from 'lodash/fp';
+
+export const INVALID_MUSTACHE_TEMPLATE = (paramKey: string) =>
+ i18n.translate(
+ 'xpack.securitySolution.detectionEngine.createRule.stepRuleActions.invalidMustacheTemplateErrorMessage',
+ {
+ defaultMessage: '{key} is not valid mustache template',
+ values: {
+ key: startCase(paramKey),
+ },
+ }
+ );
diff --git a/x-pack/plugins/security_solution/public/detections/components/rules/step_rule_actions/utils.test.ts b/x-pack/plugins/security_solution/public/detections/containers/detection_engine/rules/validate_rule_actions_field/utils.test.ts
similarity index 100%
rename from x-pack/plugins/security_solution/public/detections/components/rules/step_rule_actions/utils.test.ts
rename to x-pack/plugins/security_solution/public/detections/containers/detection_engine/rules/validate_rule_actions_field/utils.test.ts
diff --git a/x-pack/plugins/security_solution/public/detections/components/rules/step_rule_actions/utils.ts b/x-pack/plugins/security_solution/public/detections/containers/detection_engine/rules/validate_rule_actions_field/utils.ts
similarity index 100%
rename from x-pack/plugins/security_solution/public/detections/components/rules/step_rule_actions/utils.ts
rename to x-pack/plugins/security_solution/public/detections/containers/detection_engine/rules/validate_rule_actions_field/utils.ts
diff --git a/x-pack/plugins/security_solution/public/detections/components/rules/step_rule_actions/schema.test.tsx b/x-pack/plugins/security_solution/public/detections/containers/detection_engine/rules/validate_rule_actions_field/validate_rule_actions_field.test.tsx
similarity index 96%
rename from x-pack/plugins/security_solution/public/detections/components/rules/step_rule_actions/schema.test.tsx
rename to x-pack/plugins/security_solution/public/detections/containers/detection_engine/rules/validate_rule_actions_field/validate_rule_actions_field.test.tsx
index 58acba634311a..335d6faf631f5 100644
--- a/x-pack/plugins/security_solution/public/detections/components/rules/step_rule_actions/schema.test.tsx
+++ b/x-pack/plugins/security_solution/public/detections/containers/detection_engine/rules/validate_rule_actions_field/validate_rule_actions_field.test.tsx
@@ -5,13 +5,13 @@
* 2.0.
*/
-import { validateSingleAction, validateRuleActionsField } from './schema';
+import { validateSingleAction, validateRuleActionsField } from './validate_rule_actions_field';
import { getActionTypeName, validateMustache, validateActionParams } from './utils';
import { actionTypeRegistryMock } from '@kbn/triggers-actions-ui-plugin/public/application/action_type_registry.mock';
-import type { FormHook } from '../../../../shared_imports';
+import type { FormHook } from '../../../../../shared_imports';
jest.mock('./utils');
-describe('stepRuleActions schema', () => {
+describe('validate_rule_actions_field', () => {
const actionTypeRegistry = actionTypeRegistryMock.create();
describe('validateSingleAction', () => {
diff --git a/x-pack/plugins/security_solution/public/detections/components/rules/step_rule_actions/schema.tsx b/x-pack/plugins/security_solution/public/detections/containers/detection_engine/rules/validate_rule_actions_field/validate_rule_actions_field.ts
similarity index 62%
rename from x-pack/plugins/security_solution/public/detections/components/rules/step_rule_actions/schema.tsx
rename to x-pack/plugins/security_solution/public/detections/containers/detection_engine/rules/validate_rule_actions_field/validate_rule_actions_field.ts
index efc34c7b4d13d..18aa758d0a499 100644
--- a/x-pack/plugins/security_solution/public/detections/components/rules/step_rule_actions/schema.tsx
+++ b/x-pack/plugins/security_solution/public/detections/containers/detection_engine/rules/validate_rule_actions_field/validate_rule_actions_field.ts
@@ -7,19 +7,11 @@
/* istanbul ignore file */
-import { i18n } from '@kbn/i18n';
-
import type {
RuleAction,
ActionTypeRegistryContract,
} from '@kbn/triggers-actions-ui-plugin/public';
-import type {
- FormSchema,
- ValidationFunc,
- ERROR_CODE,
- ValidationError,
-} from '../../../../shared_imports';
-import type { ActionsStepRule } from '../../../pages/detection_engine/rules/types';
+import type { ValidationFunc, ERROR_CODE, ValidationError } from '../../../../../shared_imports';
import { getActionTypeName, validateMustache, validateActionParams } from './utils';
export const validateSingleAction = async (
@@ -59,34 +51,3 @@ export const validateRuleActionsField =
};
}
};
-
-export const getSchema = ({
- actionTypeRegistry,
-}: {
- actionTypeRegistry: ActionTypeRegistryContract;
-}): FormSchema => ({
- actions: {
- validations: [
- {
- validator: validateRuleActionsField(actionTypeRegistry),
- },
- ],
- },
- enabled: {},
- kibanaSiemAppUrl: {},
- throttle: {
- label: i18n.translate(
- 'xpack.securitySolution.detectionEngine.createRule.stepRuleActions.fieldThrottleLabel',
- {
- defaultMessage: 'Actions frequency',
- }
- ),
- helpText: i18n.translate(
- 'xpack.securitySolution.detectionEngine.createRule.stepRuleActions.fieldThrottleHelpText',
- {
- defaultMessage:
- 'Select when automated actions should be performed if a rule evaluates as true.',
- }
- ),
- },
-});
diff --git a/x-pack/plugins/security_solution/public/detections/pages/detection_engine/rules/all/actions.ts b/x-pack/plugins/security_solution/public/detections/pages/detection_engine/rules/all/actions.ts
index 28d3f4856579f..d80835209010f 100644
--- a/x-pack/plugins/security_solution/public/detections/pages/detection_engine/rules/all/actions.ts
+++ b/x-pack/plugins/security_solution/public/detections/pages/detection_engine/rules/all/actions.ts
@@ -7,8 +7,8 @@
import type { NavigateToAppOptions } from '@kbn/core/public';
import { APP_UI_ID } from '../../../../../../common/constants';
-import type { BulkActionEditPayload } from '../../../../../../common/detection_engine/schemas/common/schemas';
-import { BulkAction } from '../../../../../../common/detection_engine/schemas/common/schemas';
+import type { BulkActionEditPayload } from '../../../../../../common/detection_engine/schemas/request/perform_bulk_action_schema';
+import { BulkAction } from '../../../../../../common/detection_engine/schemas/request/perform_bulk_action_schema';
import type { HTTPError } from '../../../../../../common/detection_engine/types';
import { SecurityPageName } from '../../../../../app/types';
import { getEditRuleUrl } from '../../../../../common/components/link_to/redirect_to_detection_engine';
diff --git a/x-pack/plugins/security_solution/public/detections/pages/detection_engine/rules/all/bulk_actions/bulk_action_dry_run_confirmation.tsx b/x-pack/plugins/security_solution/public/detections/pages/detection_engine/rules/all/bulk_actions/bulk_action_dry_run_confirmation.tsx
index 33d325b837d33..9207e0813ab70 100644
--- a/x-pack/plugins/security_solution/public/detections/pages/detection_engine/rules/all/bulk_actions/bulk_action_dry_run_confirmation.tsx
+++ b/x-pack/plugins/security_solution/public/detections/pages/detection_engine/rules/all/bulk_actions/bulk_action_dry_run_confirmation.tsx
@@ -10,7 +10,7 @@ import { EuiConfirmModal } from '@elastic/eui';
import * as i18n from '../../translations';
import { BulkActionRuleErrorsList } from './bulk_action_rule_errors_list';
-import { BulkAction } from '../../../../../../../common/detection_engine/schemas/common/schemas';
+import { BulkAction } from '../../../../../../../common/detection_engine/schemas/request/perform_bulk_action_schema';
import { assertUnreachable } from '../../../../../../../common/utility_types';
import type { BulkActionForConfirmation, DryRunResult } from './types';
diff --git a/x-pack/plugins/security_solution/public/detections/pages/detection_engine/rules/all/bulk_actions/bulk_action_rule_errors_list.test.tsx b/x-pack/plugins/security_solution/public/detections/pages/detection_engine/rules/all/bulk_actions/bulk_action_rule_errors_list.test.tsx
index 82b78c319c056..987b244dd9fc6 100644
--- a/x-pack/plugins/security_solution/public/detections/pages/detection_engine/rules/all/bulk_actions/bulk_action_rule_errors_list.test.tsx
+++ b/x-pack/plugins/security_solution/public/detections/pages/detection_engine/rules/all/bulk_actions/bulk_action_rule_errors_list.test.tsx
@@ -13,7 +13,7 @@ import { render, screen } from '@testing-library/react';
import { BulkActionRuleErrorsList } from './bulk_action_rule_errors_list';
import { BulkActionsDryRunErrCode } from '../../../../../../../common/constants';
import type { DryRunResult } from './types';
-import { BulkAction } from '../../../../../../../common/detection_engine/schemas/common/schemas';
+import { BulkAction } from '../../../../../../../common/detection_engine/schemas/request/perform_bulk_action_schema';
const Wrapper: FC = ({ children }) => {
return (
diff --git a/x-pack/plugins/security_solution/public/detections/pages/detection_engine/rules/all/bulk_actions/bulk_action_rule_errors_list.tsx b/x-pack/plugins/security_solution/public/detections/pages/detection_engine/rules/all/bulk_actions/bulk_action_rule_errors_list.tsx
index 7f5b3ea3f74ee..8f0275000a4ef 100644
--- a/x-pack/plugins/security_solution/public/detections/pages/detection_engine/rules/all/bulk_actions/bulk_action_rule_errors_list.tsx
+++ b/x-pack/plugins/security_solution/public/detections/pages/detection_engine/rules/all/bulk_actions/bulk_action_rule_errors_list.tsx
@@ -10,7 +10,7 @@ import { EuiSpacer } from '@elastic/eui';
import { FormattedMessage } from '@kbn/i18n-react';
import { BulkActionsDryRunErrCode } from '../../../../../../../common/constants';
-import { BulkAction } from '../../../../../../../common/detection_engine/schemas/common/schemas';
+import { BulkAction } from '../../../../../../../common/detection_engine/schemas/request/perform_bulk_action_schema';
import type { DryRunResult, BulkActionForConfirmation } from './types';
diff --git a/x-pack/plugins/security_solution/public/detections/pages/detection_engine/rules/all/bulk_actions/bulk_edit_flyout.tsx b/x-pack/plugins/security_solution/public/detections/pages/detection_engine/rules/all/bulk_actions/bulk_edit_flyout.tsx
index 4a4d33c358b0e..db96a63f6245e 100644
--- a/x-pack/plugins/security_solution/public/detections/pages/detection_engine/rules/all/bulk_actions/bulk_edit_flyout.tsx
+++ b/x-pack/plugins/security_solution/public/detections/pages/detection_engine/rules/all/bulk_actions/bulk_edit_flyout.tsx
@@ -7,12 +7,13 @@
import React from 'react';
-import type { BulkActionEditPayload } from '../../../../../../../common/detection_engine/schemas/common/schemas';
-import { BulkActionEditType } from '../../../../../../../common/detection_engine/schemas/common/schemas';
+import type { BulkActionEditPayload } from '../../../../../../../common/detection_engine/schemas/request/perform_bulk_action_schema';
+import { BulkActionEditType } from '../../../../../../../common/detection_engine/schemas/request/perform_bulk_action_schema';
import { IndexPatternsForm } from './forms/index_patterns_form';
import { TagsForm } from './forms/tags_form';
import { TimelineTemplateForm } from './forms/timeline_template_form';
+import { RuleActionsForm } from './forms/rule_actions_form';
interface BulkEditFlyoutProps {
onClose: () => void;
@@ -37,6 +38,10 @@ const BulkEditFlyoutComponent = ({ editAction, tags, ...props }: BulkEditFlyoutP
case BulkActionEditType.set_timeline:
return ;
+ case BulkActionEditType.add_rule_actions:
+ case BulkActionEditType.set_rule_actions:
+ return ;
+
default:
return null;
}
diff --git a/x-pack/plugins/security_solution/public/detections/pages/detection_engine/rules/all/bulk_actions/forms/bulk_edit_form_wrapper.tsx b/x-pack/plugins/security_solution/public/detections/pages/detection_engine/rules/all/bulk_actions/forms/bulk_edit_form_wrapper.tsx
index 26a555b7de335..a4fafd8d21bfd 100644
--- a/x-pack/plugins/security_solution/public/detections/pages/detection_engine/rules/all/bulk_actions/forms/bulk_edit_form_wrapper.tsx
+++ b/x-pack/plugins/security_solution/public/detections/pages/detection_engine/rules/all/bulk_actions/forms/bulk_edit_form_wrapper.tsx
@@ -7,6 +7,7 @@
import type { FC } from 'react';
import React from 'react';
+import type { EuiFlyoutSize } from '@elastic/eui';
import {
useGeneratedHtmlId,
EuiFlyout,
@@ -32,6 +33,7 @@ interface BulkEditFormWrapperProps {
children: React.ReactNode;
onClose: () => void;
onSubmit: () => void;
+ flyoutSize?: EuiFlyoutSize;
}
const BulkEditFormWrapperComponent: FC = ({
@@ -41,6 +43,7 @@ const BulkEditFormWrapperComponent: FC = ({
children,
onClose,
onSubmit,
+ flyoutSize = 's',
}) => {
const simpleFlyoutTitleId = useGeneratedHtmlId({
prefix: 'RulesBulkEditForm',
@@ -48,7 +51,7 @@ const BulkEditFormWrapperComponent: FC = ({
const { isValid } = form;
return (
-
+
{title}
diff --git a/x-pack/plugins/security_solution/public/detections/pages/detection_engine/rules/all/bulk_actions/forms/index_patterns_form.tsx b/x-pack/plugins/security_solution/public/detections/pages/detection_engine/rules/all/bulk_actions/forms/index_patterns_form.tsx
index 2ce632be3ef3c..adb19e397027b 100644
--- a/x-pack/plugins/security_solution/public/detections/pages/detection_engine/rules/all/bulk_actions/forms/index_patterns_form.tsx
+++ b/x-pack/plugins/security_solution/public/detections/pages/detection_engine/rules/all/bulk_actions/forms/index_patterns_form.tsx
@@ -14,8 +14,8 @@ import * as i18n from '../../../translations';
import { DEFAULT_INDEX_KEY } from '../../../../../../../../common/constants';
import { useKibana } from '../../../../../../../common/lib/kibana';
-import type { BulkActionEditPayload } from '../../../../../../../../common/detection_engine/schemas/common/schemas';
-import { BulkActionEditType } from '../../../../../../../../common/detection_engine/schemas/common/schemas';
+import { BulkActionEditType } from '../../../../../../../../common/detection_engine/schemas/request/perform_bulk_action_schema';
+import type { BulkActionEditPayload } from '../../../../../../../../common/detection_engine/schemas/request/perform_bulk_action_schema';
import type { FormSchema } from '../../../../../../../shared_imports';
import {
diff --git a/x-pack/plugins/security_solution/public/detections/pages/detection_engine/rules/all/bulk_actions/forms/rule_actions_form.tsx b/x-pack/plugins/security_solution/public/detections/pages/detection_engine/rules/all/bulk_actions/forms/rule_actions_form.tsx
new file mode 100644
index 0000000000000..8a9e52c9d5528
--- /dev/null
+++ b/x-pack/plugins/security_solution/public/detections/pages/detection_engine/rules/all/bulk_actions/forms/rule_actions_form.tsx
@@ -0,0 +1,244 @@
+/*
+ * 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 { EuiCallOut, EuiSpacer } from '@elastic/eui';
+import { FormattedMessage } from '@kbn/i18n-react';
+
+import type {
+ RuleAction,
+ ActionTypeRegistryContract,
+} from '@kbn/triggers-actions-ui-plugin/public';
+import type { FormSchema } from '../../../../../../../shared_imports';
+import {
+ useForm,
+ UseField,
+ FIELD_TYPES,
+ useFormData,
+ getUseField,
+ Field,
+} from '../../../../../../../shared_imports';
+import type { BulkActionEditPayload } from '../../../../../../../../common/detection_engine/schemas/request/perform_bulk_action_schema';
+import { BulkActionEditType } from '../../../../../../../../common/detection_engine/schemas/request/perform_bulk_action_schema';
+import { NOTIFICATION_THROTTLE_NO_ACTIONS } from '../../../../../../../../common/constants';
+
+import { BulkEditFormWrapper } from './bulk_edit_form_wrapper';
+import { bulkAddRuleActions as i18n } from '../translations';
+
+import { useKibana } from '../../../../../../../common/lib/kibana';
+
+import {
+ ThrottleSelectField,
+ THROTTLE_OPTIONS,
+} from '../../../../../../components/rules/throttle_select_field';
+import { getAllActionMessageParams } from '../../../helpers';
+
+import { RuleActionsField } from '../../../../../../components/rules/rule_actions_field';
+import { validateRuleActionsField } from '../../../../../../containers/detection_engine/rules/validate_rule_actions_field';
+
+const CommonUseField = getUseField({ component: Field });
+
+export interface RuleActionsFormData {
+ throttle: string;
+ actions: RuleAction[];
+ overwrite: boolean;
+}
+
+const getFormSchema = (
+ actionTypeRegistry: ActionTypeRegistryContract
+): FormSchema => ({
+ throttle: {
+ label: i18n.THROTTLE_LABEL,
+ helpText: i18n.THROTTLE_HELP_TEXT,
+ },
+ actions: {
+ validations: [
+ {
+ validator: validateRuleActionsField(actionTypeRegistry),
+ },
+ ],
+ },
+ overwrite: {
+ type: FIELD_TYPES.CHECKBOX,
+ label: i18n.OVERWRITE_LABEL,
+ },
+});
+
+const defaultFormData: RuleActionsFormData = {
+ throttle: NOTIFICATION_THROTTLE_NO_ACTIONS,
+ actions: [],
+ overwrite: false,
+};
+
+interface RuleActionsFormProps {
+ rulesCount: number;
+ onClose: () => void;
+ onConfirm: (bulkActionEditPayload: BulkActionEditPayload) => void;
+}
+
+const RuleActionsFormComponent = ({ rulesCount, onClose, onConfirm }: RuleActionsFormProps) => {
+ const {
+ services: {
+ triggersActionsUi: { actionTypeRegistry },
+ },
+ } = useKibana();
+
+ const formSchema = useMemo(() => getFormSchema(actionTypeRegistry), [actionTypeRegistry]);
+
+ const { form } = useForm({
+ schema: formSchema,
+ defaultValue: defaultFormData,
+ });
+
+ const [{ overwrite, throttle }] = useFormData({ form, watch: ['overwrite', 'throttle'] });
+
+ const handleSubmit = useCallback(async () => {
+ const { data, isValid } = await form.submit();
+ if (!isValid) {
+ return;
+ }
+
+ const { actions = [], throttle: throttleToSubmit, overwrite: overwriteValue } = data;
+ const editAction = overwriteValue
+ ? BulkActionEditType.set_rule_actions
+ : BulkActionEditType.add_rule_actions;
+
+ onConfirm({
+ type: editAction,
+ value: {
+ actions: actions.map(({ actionTypeId, ...action }) => action),
+ throttle: throttleToSubmit,
+ },
+ });
+ }, [form, onConfirm]);
+
+ const throttleFieldComponentProps = useMemo(
+ () => ({
+ idAria: 'bulkEditRulesRuleActionThrottle',
+ dataTestSubj: 'bulkEditRulesRuleActionThrottle',
+ hasNoInitialSelection: false,
+ euiFieldProps: {
+ options: THROTTLE_OPTIONS,
+ },
+ }),
+ []
+ );
+
+ const messageVariables = useMemo(() => getAllActionMessageParams(), []);
+
+ const showActionsSelect = throttle !== NOTIFICATION_THROTTLE_NO_ACTIONS;
+
+ return (
+
+
+ }
+ >
+
+ -
+
+
+ -
+
+
+
+ ),
+ overwriteActionsCheckbox: (
+
+
+
+ ),
+ }}
+ />
+
+ - {i18n.RULE_VARIABLES_DETAIL}
+
+
+
+
+
+
+
+ {showActionsSelect && (
+ <>
+
+
+ >
+ )}
+
+
+
+ {overwrite && (
+ <>
+
+
+
+
+
+ ),
+ }}
+ />
+
+ >
+ )}
+
+ );
+};
+
+export const RuleActionsForm = React.memo(RuleActionsFormComponent);
+RuleActionsForm.displayName = 'RuleActionsForm';
diff --git a/x-pack/plugins/security_solution/public/detections/pages/detection_engine/rules/all/bulk_actions/forms/tags_form.tsx b/x-pack/plugins/security_solution/public/detections/pages/detection_engine/rules/all/bulk_actions/forms/tags_form.tsx
index 366115623d041..e53469e27a09a 100644
--- a/x-pack/plugins/security_solution/public/detections/pages/detection_engine/rules/all/bulk_actions/forms/tags_form.tsx
+++ b/x-pack/plugins/security_solution/public/detections/pages/detection_engine/rules/all/bulk_actions/forms/tags_form.tsx
@@ -11,8 +11,8 @@ import { FormattedMessage } from '@kbn/i18n-react';
import * as i18n from '../../../translations';
import { caseInsensitiveSort } from '../../helpers';
-import type { BulkActionEditPayload } from '../../../../../../../../common/detection_engine/schemas/common/schemas';
-import { BulkActionEditType } from '../../../../../../../../common/detection_engine/schemas/common/schemas';
+import type { BulkActionEditPayload } from '../../../../../../../../common/detection_engine/schemas/request/perform_bulk_action_schema';
+import { BulkActionEditType } from '../../../../../../../../common/detection_engine/schemas/request/perform_bulk_action_schema';
import type { FormSchema } from '../../../../../../../shared_imports';
import {
diff --git a/x-pack/plugins/security_solution/public/detections/pages/detection_engine/rules/all/bulk_actions/forms/timeline_template_form.tsx b/x-pack/plugins/security_solution/public/detections/pages/detection_engine/rules/all/bulk_actions/forms/timeline_template_form.tsx
index 3c5852926a5d7..6aa5a3100c100 100644
--- a/x-pack/plugins/security_solution/public/detections/pages/detection_engine/rules/all/bulk_actions/forms/timeline_template_form.tsx
+++ b/x-pack/plugins/security_solution/public/detections/pages/detection_engine/rules/all/bulk_actions/forms/timeline_template_form.tsx
@@ -11,8 +11,8 @@ import { EuiCallOut } from '@elastic/eui';
import type { FormSchema } from '../../../../../../../shared_imports';
import { useForm, UseField } from '../../../../../../../shared_imports';
import { PickTimeline } from '../../../../../../components/rules/pick_timeline';
-import type { BulkActionEditPayload } from '../../../../../../../../common/detection_engine/schemas/common/schemas';
-import { BulkActionEditType } from '../../../../../../../../common/detection_engine/schemas/common/schemas';
+import type { BulkActionEditPayload } from '../../../../../../../../common/detection_engine/schemas/request/perform_bulk_action_schema';
+import { BulkActionEditType } from '../../../../../../../../common/detection_engine/schemas/request/perform_bulk_action_schema';
import { BulkEditFormWrapper } from './bulk_edit_form_wrapper';
import { bulkApplyTimelineTemplate as i18n } from '../translations';
diff --git a/x-pack/plugins/security_solution/public/detections/pages/detection_engine/rules/all/bulk_actions/translations.tsx b/x-pack/plugins/security_solution/public/detections/pages/detection_engine/rules/all/bulk_actions/translations.tsx
index cce2d3e032a83..3c7fdd9cb7a8c 100644
--- a/x-pack/plugins/security_solution/public/detections/pages/detection_engine/rules/all/bulk_actions/translations.tsx
+++ b/x-pack/plugins/security_solution/public/detections/pages/detection_engine/rules/all/bulk_actions/translations.tsx
@@ -55,3 +55,42 @@ export const bulkApplyTimelineTemplate = {
/>
),
};
+
+export const bulkAddRuleActions = {
+ FORM_TITLE: i18n.translate(
+ 'xpack.securitySolution.detectionEngine.rules.allRules.bulkActions.edit.addRuleActions.formTitle',
+ {
+ defaultMessage: 'Add rule actions',
+ }
+ ),
+
+ OVERWRITE_LABEL: i18n.translate(
+ 'xpack.securitySolution.detectionEngine.rules.allRules.bulkActions.edit.addRuleActions.overwriteCheckboxLabel',
+ {
+ defaultMessage: 'Overwrite all selected rules actions',
+ }
+ ),
+
+ THROTTLE_LABEL: i18n.translate(
+ 'xpack.securitySolution.detectionEngine.rules.allRules.bulkActions.edit.addRuleActions.throttleLabel',
+ {
+ defaultMessage: 'Actions frequency',
+ }
+ ),
+
+ THROTTLE_HELP_TEXT: i18n.translate(
+ 'xpack.securitySolution.detectionEngine.rules.allRules.bulkActions.edit.addRuleActions.throttleHelpText',
+ {
+ defaultMessage:
+ 'Select when automated actions should be performed if a rule evaluates as true.',
+ }
+ ),
+
+ RULE_VARIABLES_DETAIL: i18n.translate(
+ 'xpack.securitySolution.detectionEngine.rules.allRules.bulkActions.edit.addRuleActions.ruleVariablesDetail',
+ {
+ defaultMessage:
+ 'Rule variables may affect only some of the rules you select, based on the rule types (for example, \\u007b\\u007bcontext.rule.threshold\\u007d\\u007d will only display values for threshold rules).',
+ }
+ ),
+};
diff --git a/x-pack/plugins/security_solution/public/detections/pages/detection_engine/rules/all/bulk_actions/types.ts b/x-pack/plugins/security_solution/public/detections/pages/detection_engine/rules/all/bulk_actions/types.ts
index 9041e83167469..d81c7c995a2fe 100644
--- a/x-pack/plugins/security_solution/public/detections/pages/detection_engine/rules/all/bulk_actions/types.ts
+++ b/x-pack/plugins/security_solution/public/detections/pages/detection_engine/rules/all/bulk_actions/types.ts
@@ -6,7 +6,7 @@
*/
import type { BulkActionsDryRunErrCode } from '../../../../../../../common/constants';
-import type { BulkAction } from '../../../../../../../common/detection_engine/schemas/common/schemas';
+import type { BulkAction } from '../../../../../../../common/detection_engine/schemas/request/perform_bulk_action_schema';
/**
* Only 2 bulk actions are supported for for confirmation dry run modal:
diff --git a/x-pack/plugins/security_solution/public/detections/pages/detection_engine/rules/all/bulk_actions/use_bulk_actions.tsx b/x-pack/plugins/security_solution/public/detections/pages/detection_engine/rules/all/bulk_actions/use_bulk_actions.tsx
index 9c5383dc1a693..84da6c6cc6882 100644
--- a/x-pack/plugins/security_solution/public/detections/pages/detection_engine/rules/all/bulk_actions/use_bulk_actions.tsx
+++ b/x-pack/plugins/security_solution/public/detections/pages/detection_engine/rules/all/bulk_actions/use_bulk_actions.tsx
@@ -14,11 +14,11 @@ import { useIsMounted } from '@kbn/securitysolution-hook-utils';
import type { Toast } from '@kbn/core/public';
import { toMountPoint } from '@kbn/kibana-react-plugin/public';
-import type { BulkActionEditPayload } from '../../../../../../../common/detection_engine/schemas/common/schemas';
+import type { BulkActionEditPayload } from '../../../../../../../common/detection_engine/schemas/request/perform_bulk_action_schema';
import {
BulkAction,
BulkActionEditType,
-} from '../../../../../../../common/detection_engine/schemas/common/schemas';
+} from '../../../../../../../common/detection_engine/schemas/request/perform_bulk_action_schema';
import { isMlRule } from '../../../../../../../common/machine_learning/helpers';
import { canEditRuleWithActions } from '../../../../../../common/utils/privileges';
import { useRulesTableContext } from '../rules_table/rules_table_context';
@@ -360,6 +360,16 @@ export const useBulkActions = ({
disabled: isEditDisabled,
panel: 1,
},
+ {
+ key: i18n.BULK_ACTION_ADD_RULE_ACTIONS,
+ name: i18n.BULK_ACTION_ADD_RULE_ACTIONS,
+ 'data-test-subj': 'addRuleActionsBulk',
+ disabled: isEditDisabled,
+ onClick: handleBulkEdit(BulkActionEditType.add_rule_actions),
+ toolTipContent: missingActionPrivileges ? i18n.EDIT_RULE_SETTINGS_TOOLTIP : undefined,
+ toolTipPosition: 'right',
+ icon: undefined,
+ },
{
key: i18n.BULK_ACTION_APPLY_TIMELINE_TEMPLATE,
name: i18n.BULK_ACTION_APPLY_TIMELINE_TEMPLATE,
diff --git a/x-pack/plugins/security_solution/public/detections/pages/detection_engine/rules/all/bulk_actions/use_bulk_actions_dry_run.ts b/x-pack/plugins/security_solution/public/detections/pages/detection_engine/rules/all/bulk_actions/use_bulk_actions_dry_run.ts
index 28c4e4be608dc..5e14c0a57bf51 100644
--- a/x-pack/plugins/security_solution/public/detections/pages/detection_engine/rules/all/bulk_actions/use_bulk_actions_dry_run.ts
+++ b/x-pack/plugins/security_solution/public/detections/pages/detection_engine/rules/all/bulk_actions/use_bulk_actions_dry_run.ts
@@ -11,7 +11,7 @@ import { useMutation } from '@tanstack/react-query';
import type {
BulkAction,
BulkActionEditType,
-} from '../../../../../../../common/detection_engine/schemas/common/schemas';
+} from '../../../../../../../common/detection_engine/schemas/request/perform_bulk_action_schema';
import type { BulkActionResponse } from '../../../../../containers/detection_engine/rules';
import { performBulkAction } from '../../../../../containers/detection_engine/rules';
import { computeDryRunPayload } from './utils/compute_dry_run_payload';
diff --git a/x-pack/plugins/security_solution/public/detections/pages/detection_engine/rules/all/bulk_actions/use_bulk_edit_form_flyout.ts b/x-pack/plugins/security_solution/public/detections/pages/detection_engine/rules/all/bulk_actions/use_bulk_edit_form_flyout.ts
index babdd1bfa536e..6d629ae1869b4 100644
--- a/x-pack/plugins/security_solution/public/detections/pages/detection_engine/rules/all/bulk_actions/use_bulk_edit_form_flyout.ts
+++ b/x-pack/plugins/security_solution/public/detections/pages/detection_engine/rules/all/bulk_actions/use_bulk_edit_form_flyout.ts
@@ -8,9 +8,9 @@ import { useState, useCallback, useRef } from 'react';
import { useAsyncConfirmation } from '../rules_table/use_async_confirmation';
import type {
- BulkActionEditType,
BulkActionEditPayload,
-} from '../../../../../../../common/detection_engine/schemas/common/schemas';
+ BulkActionEditType,
+} from '../../../../../../../common/detection_engine/schemas/request/perform_bulk_action_schema';
import { useBoolState } from '../../../../../../common/hooks/use_bool_state';
export const useBulkEditFormFlyout = () => {
diff --git a/x-pack/plugins/security_solution/public/detections/pages/detection_engine/rules/all/bulk_actions/utils/compute_dry_run_payload.test.ts b/x-pack/plugins/security_solution/public/detections/pages/detection_engine/rules/all/bulk_actions/utils/compute_dry_run_payload.test.ts
index cbdb34654a99b..361f7edc4823f 100644
--- a/x-pack/plugins/security_solution/public/detections/pages/detection_engine/rules/all/bulk_actions/utils/compute_dry_run_payload.test.ts
+++ b/x-pack/plugins/security_solution/public/detections/pages/detection_engine/rules/all/bulk_actions/utils/compute_dry_run_payload.test.ts
@@ -8,7 +8,7 @@
import {
BulkAction,
BulkActionEditType,
-} from '../../../../../../../../common/detection_engine/schemas/common/schemas';
+} from '../../../../../../../../common/detection_engine/schemas/request/perform_bulk_action_schema';
import { computeDryRunPayload } from './compute_dry_run_payload';
diff --git a/x-pack/plugins/security_solution/public/detections/pages/detection_engine/rules/all/bulk_actions/utils/compute_dry_run_payload.ts b/x-pack/plugins/security_solution/public/detections/pages/detection_engine/rules/all/bulk_actions/utils/compute_dry_run_payload.ts
index d50d6840e899a..c6128100985b0 100644
--- a/x-pack/plugins/security_solution/public/detections/pages/detection_engine/rules/all/bulk_actions/utils/compute_dry_run_payload.ts
+++ b/x-pack/plugins/security_solution/public/detections/pages/detection_engine/rules/all/bulk_actions/utils/compute_dry_run_payload.ts
@@ -5,11 +5,12 @@
* 2.0.
*/
-import type { BulkActionEditPayload } from '../../../../../../../../common/detection_engine/schemas/common/schemas';
+import type { BulkActionEditPayload } from '../../../../../../../../common/detection_engine/schemas/request/perform_bulk_action_schema';
import {
BulkAction,
BulkActionEditType,
-} from '../../../../../../../../common/detection_engine/schemas/common/schemas';
+} from '../../../../../../../../common/detection_engine/schemas/request/perform_bulk_action_schema';
+import { assertUnreachable } from '../../../../../../../../common/utility_types';
/**
* helper utility that creates payload for _bulk_action API in dry mode
@@ -53,5 +54,17 @@ export const computeDryRunPayload = (
value: { timeline_id: '', timeline_title: '' },
},
];
+
+ case BulkActionEditType.add_rule_actions:
+ case BulkActionEditType.set_rule_actions:
+ return [
+ {
+ type: editAction,
+ value: { throttle: '1h', actions: [] },
+ },
+ ];
+
+ default:
+ assertUnreachable(editAction);
}
};
diff --git a/x-pack/plugins/security_solution/public/detections/pages/detection_engine/rules/all/rules_table_actions.tsx b/x-pack/plugins/security_solution/public/detections/pages/detection_engine/rules/all/rules_table_actions.tsx
index 8e32583a54c9b..cfd83c3ab408f 100644
--- a/x-pack/plugins/security_solution/public/detections/pages/detection_engine/rules/all/rules_table_actions.tsx
+++ b/x-pack/plugins/security_solution/public/detections/pages/detection_engine/rules/all/rules_table_actions.tsx
@@ -9,7 +9,7 @@ import type { DefaultItemAction } from '@elastic/eui';
import { EuiToolTip } from '@elastic/eui';
import React from 'react';
import type { NavigateToAppOptions } from '@kbn/core/public';
-import { BulkAction } from '../../../../../../common/detection_engine/schemas/common/schemas';
+import { BulkAction } from '../../../../../../common/detection_engine/schemas/request/perform_bulk_action_schema';
import type { UseAppToasts } from '../../../../../common/hooks/use_app_toasts';
import { canEditRuleWithActions } from '../../../../../common/utils/privileges';
import type { Rule } from '../../../../containers/detection_engine/rules';
diff --git a/x-pack/plugins/security_solution/public/detections/pages/detection_engine/rules/helpers.tsx b/x-pack/plugins/security_solution/public/detections/pages/detection_engine/rules/helpers.tsx
index 86a54e099e7b2..278ed497d12e8 100644
--- a/x-pack/plugins/security_solution/public/detections/pages/detection_engine/rules/helpers.tsx
+++ b/x-pack/plugins/security_solution/public/detections/pages/detection_engine/rules/helpers.tsx
@@ -361,14 +361,44 @@ export const redirectToDetections = (
hasEncryptionKey === false ||
needsListsConfiguration;
-const getRuleSpecificRuleParamKeys = (ruleType: Type) => {
- const queryRuleParams = ['index', 'filters', 'language', 'query', 'saved_id'];
+const commonRuleParamsKeys = [
+ 'id',
+ 'name',
+ 'description',
+ 'false_positives',
+ 'rule_id',
+ 'max_signals',
+ 'risk_score',
+ 'output_index',
+ 'references',
+ 'severity',
+ 'timeline_id',
+ 'timeline_title',
+ 'threat',
+ 'type',
+ 'version',
+];
+const queryRuleParams = ['index', 'filters', 'language', 'query', 'saved_id'];
+const machineLearningRuleParams = ['anomaly_threshold', 'machine_learning_job_id'];
+const thresholdRuleParams = ['threshold', ...queryRuleParams];
+
+const getAllRuleParamsKeys = (): string[] => {
+ const allRuleParamsKeys = [
+ ...commonRuleParamsKeys,
+ ...queryRuleParams,
+ ...machineLearningRuleParams,
+ ...thresholdRuleParams,
+ ].sort();
+ return Array.from(new Set(allRuleParamsKeys));
+};
+
+const getRuleSpecificRuleParamKeys = (ruleType: Type) => {
switch (ruleType) {
case 'machine_learning':
- return ['anomaly_threshold', 'machine_learning_job_id'];
+ return machineLearningRuleParams;
case 'threshold':
- return ['threshold', ...queryRuleParams];
+ return thresholdRuleParams;
case 'new_terms':
case 'threat_match':
case 'query':
@@ -380,24 +410,6 @@ const getRuleSpecificRuleParamKeys = (ruleType: Type) => {
};
export const getActionMessageRuleParams = (ruleType: Type): string[] => {
- const commonRuleParamsKeys = [
- 'id',
- 'name',
- 'description',
- 'false_positives',
- 'rule_id',
- 'max_signals',
- 'risk_score',
- 'output_index',
- 'references',
- 'severity',
- 'timeline_id',
- 'timeline_title',
- 'threat',
- 'type',
- 'version',
- ];
-
const ruleParamsKeys = [
...commonRuleParamsKeys,
...getRuleSpecificRuleParamKeys(ruleType),
@@ -406,12 +418,7 @@ export const getActionMessageRuleParams = (ruleType: Type): string[] => {
return ruleParamsKeys;
};
-export const getActionMessageParams = memoizeOne((ruleType: Type | undefined): ActionVariables => {
- if (!ruleType) {
- return { state: [], params: [] };
- }
- const actionMessageRuleParams = getActionMessageRuleParams(ruleType);
- // Prefixes are being added automatically by the ActionTypeForm
+const transformRuleKeysToActionVariables = (actionMessageRuleParams: string[]): ActionVariables => {
return {
state: [{ name: 'signals_count', description: 'state.signals_count' }],
params: [],
@@ -428,8 +435,23 @@ export const getActionMessageParams = memoizeOne((ruleType: Type | undefined): A
}),
],
};
+};
+
+export const getActionMessageParams = memoizeOne((ruleType: Type | undefined): ActionVariables => {
+ if (!ruleType) {
+ return { state: [], params: [] };
+ }
+ const actionMessageRuleParams = getActionMessageRuleParams(ruleType);
+
+ return transformRuleKeysToActionVariables(actionMessageRuleParams);
});
+/**
+ * returns action variables available for all rule types
+ */
+export const getAllActionMessageParams = () =>
+ transformRuleKeysToActionVariables(getAllRuleParamsKeys());
+
// typed as null not undefined as the initial state for this value is null.
export const userHasPermissions = (canUserCRUD: boolean | null): boolean =>
canUserCRUD != null ? canUserCRUD : true;
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 c732c0a536b73..676356130bada 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
@@ -180,6 +180,13 @@ export const BULK_ACTION_APPLY_TIMELINE_TEMPLATE = i18n.translate(
}
);
+export const BULK_ACTION_ADD_RULE_ACTIONS = i18n.translate(
+ 'xpack.securitySolution.detectionEngine.rules.allRules.bulkActions.addRuleActionsTitle',
+ {
+ defaultMessage: 'Add rule actions',
+ }
+);
+
export const BULK_ACTION_MENU_TITLE = i18n.translate(
'xpack.securitySolution.detectionEngine.rules.allRules.bulkActions.contextMenuTitle',
{
diff --git a/x-pack/plugins/security_solution/public/management/components/endpoint_responder/release_action.test.tsx b/x-pack/plugins/security_solution/public/management/components/endpoint_responder/release_action.test.tsx
index e6764185ed8e7..e729185b220cc 100644
--- a/x-pack/plugins/security_solution/public/management/components/endpoint_responder/release_action.test.tsx
+++ b/x-pack/plugins/security_solution/public/management/components/endpoint_responder/release_action.test.tsx
@@ -20,7 +20,8 @@ import { getDeferred } from '../mocks';
import type { ResponderCapabilities } from '../../../../common/endpoint/constants';
import { RESPONDER_CAPABILITIES } from '../../../../common/endpoint/constants';
-describe('When using the release action from response actions console', () => {
+// FLAKY: https://github.com/elastic/kibana/issues/139641
+describe.skip('When using the release action from response actions console', () => {
let render: (
capabilities?: ResponderCapabilities[]
) => Promise>;
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 5ff3794d5d00d..bd685be8d4836 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
@@ -189,7 +189,7 @@ describe('Response Actions Log', () => {
).toEqual(['Time', 'Command', 'User', 'Comments', 'Status', 'Expand rows']);
});
- it('should show `Host` column when `showHostNames` is TRUE', async () => {
+ it('should show `Hosts` column when `showHostNames` is TRUE', async () => {
render({ showHostNames: true });
expect(
@@ -201,6 +201,73 @@ describe('Response Actions Log', () => {
).toEqual(['Time', 'Command', 'User', 'Hosts', 'Comments', 'Status', 'Expand rows']);
});
+ it('should show multiple hostnames correctly', async () => {
+ const data = await getActionListMock({ actionCount: 1 });
+ data.data[0] = {
+ ...data.data[0],
+ hosts: {
+ ...data.data[0].hosts,
+ 'agent-b': { name: 'Host-agent-b' },
+ 'agent-c': { name: '' },
+ 'agent-d': { name: 'Host-agent-d' },
+ },
+ };
+
+ mockUseGetEndpointActionList = {
+ ...baseMockedActionList,
+ data,
+ };
+ render({ showHostNames: true });
+
+ expect(renderResult.getByTestId(`${testPrefix}-column-hostname`)).toHaveTextContent(
+ 'Host-agent-a, Host-agent-b, Host-agent-d'
+ );
+ });
+
+ it('should show display host is unenrolled for a single agent action when metadata host name is empty', async () => {
+ const data = await getActionListMock({ actionCount: 1 });
+ data.data[0] = {
+ ...data.data[0],
+ hosts: {
+ ...data.data[0].hosts,
+ 'agent-a': { name: '' },
+ },
+ };
+
+ mockUseGetEndpointActionList = {
+ ...baseMockedActionList,
+ data,
+ };
+ render({ showHostNames: true });
+
+ expect(renderResult.getByTestId(`${testPrefix}-column-hostname`)).toHaveTextContent(
+ 'Host unenrolled'
+ );
+ });
+
+ it('should show display host is unenrolled for a single agent action when metadata host names are empty', async () => {
+ const data = await getActionListMock({ actionCount: 1 });
+ data.data[0] = {
+ ...data.data[0],
+ hosts: {
+ ...data.data[0].hosts,
+ 'agent-a': { name: '' },
+ 'agent-b': { name: '' },
+ 'agent-c': { name: '' },
+ },
+ };
+
+ mockUseGetEndpointActionList = {
+ ...baseMockedActionList,
+ data,
+ };
+ render({ showHostNames: true });
+
+ expect(renderResult.getByTestId(`${testPrefix}-column-hostname`)).toHaveTextContent(
+ 'Hosts unenrolled'
+ );
+ });
+
it('should paginate table when there is data', async () => {
render();
diff --git a/x-pack/plugins/security_solution/public/management/components/endpoint_response_actions_list/response_actions_log.tsx b/x-pack/plugins/security_solution/public/management/components/endpoint_response_actions_list/response_actions_log.tsx
index b279a8bf8f9ba..81137f6630ac3 100644
--- a/x-pack/plugins/security_solution/public/management/components/endpoint_response_actions_list/response_actions_log.tsx
+++ b/x-pack/plugins/security_solution/public/management/components/endpoint_response_actions_list/response_actions_log.tsx
@@ -326,27 +326,38 @@ export const ResponseActionsLog = memo<
name: TABLE_COLUMN_NAMES.hosts,
width: '20%',
truncateText: true,
- render: (hosts: ActionDetails['hosts']) => {
+ render: (_hosts: ActionDetails['hosts']) => {
+ const hosts = _hosts && Object.values(_hosts);
// join hostnames if the action is for multiple agents
// and skip empty strings for names if any
- const hostname =
- hosts &&
- Object.values(hosts)
- .reduce((acc, host) => {
- if (host.name.trim()) {
- acc.push(host.name);
- }
- return acc;
- }, [])
- .join(', ');
+ const _hostnames = hosts
+ .reduce((acc, host) => {
+ if (host.name.trim()) {
+ acc.push(host.name);
+ }
+ return acc;
+ }, [])
+ .join(', ');
+
+ let hostnames = _hostnames;
+ if (!_hostnames) {
+ if (hosts.length > 1) {
+ // when action was for a single agent and no host name
+ hostnames = UX_MESSAGES.unenrolled.hosts;
+ } else if (hosts.length === 1) {
+ // when action was for a multiple agents
+ // and none of them have a host name
+ hostnames = UX_MESSAGES.unenrolled.host;
+ }
+ }
return (
-
+
- {hostname}
+ {hostnames}
);
diff --git a/x-pack/plugins/security_solution/public/management/components/endpoint_response_actions_list/translations.tsx b/x-pack/plugins/security_solution/public/management/components/endpoint_response_actions_list/translations.tsx
index 8ccadddc159ed..667516f86fe0c 100644
--- a/x-pack/plugins/security_solution/public/management/components/endpoint_response_actions_list/translations.tsx
+++ b/x-pack/plugins/security_solution/public/management/components/endpoint_response_actions_list/translations.tsx
@@ -126,6 +126,20 @@ export const UX_MESSAGES = Object.freeze({
defaultMessage: 'Pending',
}),
},
+ unenrolled: {
+ hosts: i18n.translate(
+ 'xpack.securitySolution.responseActionsList.list.item.hosts.unenrolled.hosts',
+ {
+ defaultMessage: 'Hosts unenrolled',
+ }
+ ),
+ host: i18n.translate(
+ 'xpack.securitySolution.responseActionsList.list.item.hosts.unenrolled.host',
+ {
+ defaultMessage: 'Host unenrolled',
+ }
+ ),
+ },
screenReaderExpand: i18n.translate(
'xpack.securitySolution.responseActionsList.list.screenReader.expand',
{
diff --git a/x-pack/plugins/security_solution/public/risk_score/containers/all/index.test.tsx b/x-pack/plugins/security_solution/public/risk_score/containers/all/index.test.tsx
index 66fbb1d73bd74..1777d788f866c 100644
--- a/x-pack/plugins/security_solution/public/risk_score/containers/all/index.test.tsx
+++ b/x-pack/plugins/security_solution/public/risk_score/containers/all/index.test.tsx
@@ -34,149 +34,64 @@ const mockRefetch = jest.fn();
let appToastsMock: jest.Mocked>;
-describe('useHostRiskScore', () => {
- beforeEach(() => {
- jest.clearAllMocks();
- appToastsMock = useAppToastsMock.create();
- (useAppToasts as jest.Mock).mockReturnValue(appToastsMock);
- });
-
- test('does not search if feature is not enabled', () => {
- mockUseIsExperimentalFeatureEnabled.mockReturnValue(false);
- mockUseSearchStrategy.mockReturnValue({
- loading: false,
- result: {
- data: undefined,
- totalCount: 0,
- },
- search: mockSearch,
- refetch: mockRefetch,
- inspect: {},
- error: undefined,
- });
- const { result } = renderHook(() => useHostRiskScore(), {
- wrapper: TestProviders,
- });
- expect(mockSearch).not.toHaveBeenCalled();
- expect(result.current).toEqual([
- false,
- {
- data: undefined,
- inspect: {},
- isInspected: false,
- isModuleEnabled: false,
- refetch: mockRefetch,
- totalCount: 0,
- },
- ]);
- });
-
- test('handle index not found error', () => {
- mockUseIsExperimentalFeatureEnabled.mockReturnValue(true);
-
- mockUseSearchStrategy.mockReturnValue({
- loading: false,
- result: {
- data: undefined,
- totalCount: 0,
- },
- search: mockSearch,
- refetch: mockRefetch,
- inspect: {},
- error: {
- attributes: {
- caused_by: {
- type: 'index_not_found_exception',
- },
+[useHostRiskScore, useUserRiskScore].forEach((fn) => {
+ const riskEntity = fn.name === 'useHostRiskScore' ? 'host' : 'user';
+ describe(`${fn.name}`, () => {
+ beforeEach(() => {
+ jest.clearAllMocks();
+ appToastsMock = useAppToastsMock.create();
+ (useAppToasts as jest.Mock).mockReturnValue(appToastsMock);
+ });
+ test('does not search if feature is not enabled', () => {
+ mockUseIsExperimentalFeatureEnabled.mockReturnValue(false);
+ mockUseSearchStrategy.mockReturnValue({
+ loading: false,
+ result: {
+ data: undefined,
+ totalCount: 0,
},
- },
- });
- const { result } = renderHook(() => useHostRiskScore(), {
- wrapper: TestProviders,
- });
- expect(result.current).toEqual([
- false,
- {
- data: undefined,
- inspect: {},
- isInspected: false,
- isModuleEnabled: false,
+ search: mockSearch,
refetch: mockRefetch,
- totalCount: 0,
- },
- ]);
- });
-
- test('show error toast', () => {
- mockUseIsExperimentalFeatureEnabled.mockReturnValue(true);
-
- const error = new Error();
- mockUseSearchStrategy.mockReturnValue({
- loading: false,
- result: {
- data: undefined,
- totalCount: 0,
- },
- search: mockSearch,
- refetch: mockRefetch,
- inspect: {},
- error,
- });
- renderHook(() => useHostRiskScore(), {
- wrapper: TestProviders,
- });
- expect(appToastsMock.addError).toHaveBeenCalledWith(error, {
- title: 'Failed to run search on risk score',
- });
- });
-
- test('runs search if feature is enabled', () => {
- mockUseIsExperimentalFeatureEnabled.mockReturnValue(true);
- mockUseSearchStrategy.mockReturnValue({
- loading: false,
- result: {
- data: [],
- totalCount: 0,
- },
- search: mockSearch,
- refetch: mockRefetch,
- inspect: {},
- error: undefined,
- });
- renderHook(() => useHostRiskScore(), {
- wrapper: TestProviders,
- });
- expect(mockSearch).toHaveBeenCalledWith({
- defaultIndex: ['ml_host_risk_score_latest_default'],
- factoryQueryType: 'hostsRiskScore',
- filterQuery: undefined,
- pagination: undefined,
- timerange: undefined,
- sort: undefined,
+ inspect: {},
+ error: undefined,
+ });
+ const { result } = renderHook(() => fn(), {
+ wrapper: TestProviders,
+ });
+ expect(mockSearch).not.toHaveBeenCalled();
+ expect(result.current).toEqual([
+ false,
+ {
+ data: undefined,
+ inspect: {},
+ isInspected: false,
+ isModuleEnabled: false,
+ refetch: mockRefetch,
+ totalCount: 0,
+ },
+ ]);
});
- });
- test('return result', async () => {
- mockUseIsExperimentalFeatureEnabled.mockReturnValue(true);
- mockUseSearchStrategy.mockReturnValue({
- loading: false,
- result: {
- data: [],
- totalCount: 0,
- },
- search: mockSearch,
- refetch: mockRefetch,
- inspect: {},
- error: undefined,
- });
- const { result, waitFor } = renderHook(() => useHostRiskScore(), {
- wrapper: TestProviders,
- });
- await waitFor(() => {
+ test('if query skipped and feature is enabled, isModuleEnabled should be true', () => {
+ mockUseIsExperimentalFeatureEnabled.mockReturnValue(true);
+ mockUseSearchStrategy.mockReturnValue({
+ loading: false,
+ result: {
+ data: undefined,
+ totalCount: 0,
+ },
+ search: mockSearch,
+ refetch: mockRefetch,
+ inspect: {},
+ error: undefined,
+ });
+ const { result } = renderHook(() => fn({ skip: true }), {
+ wrapper: TestProviders,
+ });
expect(result.current).toEqual([
false,
{
- data: [],
+ data: undefined,
inspect: {},
isInspected: false,
isModuleEnabled: true,
@@ -185,159 +100,121 @@ describe('useHostRiskScore', () => {
},
]);
});
- });
-});
-describe('useUserRiskScore', () => {
- beforeEach(() => {
- jest.clearAllMocks();
- appToastsMock = useAppToastsMock.create();
- (useAppToasts as jest.Mock).mockReturnValue(appToastsMock);
- });
+ test('handle index not found error', () => {
+ mockUseIsExperimentalFeatureEnabled.mockReturnValue(true);
- test('does not search if feature is not enabled', () => {
- mockUseIsExperimentalFeatureEnabled.mockReturnValue(false);
- mockUseSearchStrategy.mockReturnValue({
- loading: false,
- result: {
- data: undefined,
- totalCount: 0,
- },
- search: mockSearch,
- refetch: mockRefetch,
- inspect: {},
- error: undefined,
- });
- const { result } = renderHook(() => useUserRiskScore(), {
- wrapper: TestProviders,
- });
- expect(mockSearch).not.toHaveBeenCalled();
- expect(result.current).toEqual([
- false,
- {
- data: undefined,
- inspect: {},
- isInspected: false,
- isModuleEnabled: false,
+ mockUseSearchStrategy.mockReturnValue({
+ loading: false,
+ result: {
+ data: undefined,
+ totalCount: 0,
+ },
+ search: mockSearch,
refetch: mockRefetch,
- totalCount: 0,
- },
- ]);
- });
-
- test('handle index not found error', () => {
- mockUseIsExperimentalFeatureEnabled.mockReturnValue(true);
-
- mockUseSearchStrategy.mockReturnValue({
- loading: false,
- result: {
- data: undefined,
- totalCount: 0,
- },
- search: mockSearch,
- refetch: mockRefetch,
- inspect: {},
- error: {
- attributes: {
- caused_by: {
- type: 'index_not_found_exception',
+ inspect: {},
+ error: {
+ attributes: {
+ caused_by: {
+ type: 'index_not_found_exception',
+ },
},
},
- },
- });
- const { result } = renderHook(() => useUserRiskScore(), {
- wrapper: TestProviders,
- });
- expect(result.current).toEqual([
- false,
- {
- data: undefined,
- inspect: {},
- isInspected: false,
- isModuleEnabled: false,
- refetch: mockRefetch,
- totalCount: 0,
- },
- ]);
- });
-
- test('show error toast', () => {
- mockUseIsExperimentalFeatureEnabled.mockReturnValue(true);
-
- const error = new Error();
- mockUseSearchStrategy.mockReturnValue({
- loading: false,
- result: {
- data: undefined,
- totalCount: 0,
- },
- search: mockSearch,
- refetch: mockRefetch,
- inspect: {},
- error,
- });
- renderHook(() => useUserRiskScore(), {
- wrapper: TestProviders,
- });
- expect(appToastsMock.addError).toHaveBeenCalledWith(error, {
- title: 'Failed to run search on risk score',
- });
- });
-
- test('runs search if feature is enabled', () => {
- mockUseIsExperimentalFeatureEnabled.mockReturnValue(true);
- mockUseSearchStrategy.mockReturnValue({
- loading: false,
- result: {
- data: [],
- totalCount: 0,
- },
- search: mockSearch,
- refetch: mockRefetch,
- inspect: {},
- error: undefined,
- });
- renderHook(() => useUserRiskScore(), {
- wrapper: TestProviders,
- });
- expect(mockSearch).toHaveBeenCalledWith({
- defaultIndex: ['ml_user_risk_score_latest_default'],
- factoryQueryType: 'usersRiskScore',
- filterQuery: undefined,
- pagination: undefined,
- timerange: undefined,
- sort: undefined,
- });
- });
-
- test('return result', async () => {
- mockUseIsExperimentalFeatureEnabled.mockReturnValue(true);
- mockUseSearchStrategy.mockReturnValue({
- loading: false,
- result: {
- data: [],
- totalCount: 0,
- },
- search: mockSearch,
- refetch: mockRefetch,
- inspect: {},
- error: undefined,
- });
- const { result, waitFor } = renderHook(() => useUserRiskScore(), {
- wrapper: TestProviders,
- });
- await waitFor(() => {
+ });
+ const { result } = renderHook(() => fn(), {
+ wrapper: TestProviders,
+ });
expect(result.current).toEqual([
false,
{
- data: [],
+ data: undefined,
inspect: {},
isInspected: false,
- isModuleEnabled: true,
+ isModuleEnabled: false,
refetch: mockRefetch,
totalCount: 0,
},
]);
});
+
+ test('show error toast', () => {
+ mockUseIsExperimentalFeatureEnabled.mockReturnValue(true);
+
+ const error = new Error();
+ mockUseSearchStrategy.mockReturnValue({
+ loading: false,
+ result: {
+ data: undefined,
+ totalCount: 0,
+ },
+ search: mockSearch,
+ refetch: mockRefetch,
+ inspect: {},
+ error,
+ });
+ renderHook(() => fn(), {
+ wrapper: TestProviders,
+ });
+ expect(appToastsMock.addError).toHaveBeenCalledWith(error, {
+ title: 'Failed to run search on risk score',
+ });
+ });
+
+ test('runs search if feature is enabled', () => {
+ mockUseIsExperimentalFeatureEnabled.mockReturnValue(true);
+ mockUseSearchStrategy.mockReturnValue({
+ loading: false,
+ result: {
+ data: [],
+ totalCount: 0,
+ },
+ search: mockSearch,
+ refetch: mockRefetch,
+ inspect: {},
+ error: undefined,
+ });
+ renderHook(() => fn(), {
+ wrapper: TestProviders,
+ });
+ expect(mockSearch).toHaveBeenCalledWith({
+ defaultIndex: [`ml_${riskEntity}_risk_score_latest_default`],
+ factoryQueryType: `${riskEntity}sRiskScore`,
+ filterQuery: undefined,
+ pagination: undefined,
+ timerange: undefined,
+ sort: undefined,
+ });
+ });
+
+ test('return result', async () => {
+ mockUseIsExperimentalFeatureEnabled.mockReturnValue(true);
+ mockUseSearchStrategy.mockReturnValue({
+ loading: false,
+ result: {
+ data: [],
+ totalCount: 0,
+ },
+ search: mockSearch,
+ refetch: mockRefetch,
+ inspect: {},
+ error: undefined,
+ });
+ const { result, waitFor } = renderHook(() => fn(), {
+ wrapper: TestProviders,
+ });
+ await waitFor(() => {
+ expect(result.current).toEqual([
+ false,
+ {
+ data: [],
+ inspect: {},
+ isInspected: false,
+ isModuleEnabled: true,
+ refetch: mockRefetch,
+ totalCount: 0,
+ },
+ ]);
+ });
+ });
});
});
diff --git a/x-pack/plugins/security_solution/public/risk_score/containers/all/index.tsx b/x-pack/plugins/security_solution/public/risk_score/containers/all/index.tsx
index ec1bf63ca3b39..ef58555629c81 100644
--- a/x-pack/plugins/security_solution/public/risk_score/containers/all/index.tsx
+++ b/x-pack/plugins/security_solution/public/risk_score/containers/all/index.tsx
@@ -67,6 +67,7 @@ export const useHostRiskScore = (params?: UseRiskScoreParams) => {
const spaceId = useSpaceId();
const defaultIndex = spaceId ? getHostRiskIndex(spaceId, onlyLatest) : undefined;
const riskyHostsFeatureEnabled = useIsExperimentalFeatureEnabled('riskyHostsEnabled');
+
return useRiskScore({
timerange,
onlyLatest,
@@ -133,10 +134,10 @@ const useRiskScore = ((acc, id) => {
- acc[id] = { name: agentsHostInfo[id] };
+ acc[id] = { name: agentsHostInfo[id] ?? '' };
return acc;
}, {}),
command: normalizedActionRequest.command,
diff --git a/x-pack/plugins/security_solution/server/endpoint/services/actions/action_list.test.ts b/x-pack/plugins/security_solution/server/endpoint/services/actions/action_list.test.ts
index b2c78c2c3b9db..7ec4330586b8b 100644
--- a/x-pack/plugins/security_solution/server/endpoint/services/actions/action_list.test.ts
+++ b/x-pack/plugins/security_solution/server/endpoint/services/actions/action_list.test.ts
@@ -115,6 +115,97 @@ describe('When using `getActionList()', () => {
});
});
+ it('should return expected output for multiple agent ids', async () => {
+ const agentIds = ['agent-a', 'agent-b', 'agent-x'];
+ actionRequests = createActionRequestsEsSearchResultsMock(agentIds);
+ actionResponses = createActionResponsesEsSearchResultsMock(agentIds);
+
+ applyActionListEsSearchMock(esClient, actionRequests, actionResponses);
+ const doc = actionRequests.hits.hits[0]._source;
+ // mock metadataService.findHostMetadataForFleetAgents resolved value
+ (endpointAppContextService.getEndpointMetadataService as jest.Mock) = jest
+ .fn()
+ .mockReturnValue({
+ findHostMetadataForFleetAgents: jest.fn().mockResolvedValue([
+ {
+ agent: {
+ id: 'agent-a',
+ },
+ host: {
+ hostname: 'Host-agent-a',
+ },
+ },
+ {
+ agent: {
+ id: 'agent-b',
+ },
+ host: {
+ hostname: 'Host-agent-b',
+ },
+ },
+ ]),
+ });
+ await expect(
+ getActionList({
+ esClient,
+ logger,
+ metadataService: endpointAppContextService.getEndpointMetadataService(),
+ page: 1,
+ pageSize: 10,
+ })
+ ).resolves.toEqual({
+ page: 1,
+ pageSize: 10,
+ commands: undefined,
+ userIds: undefined,
+ startDate: undefined,
+ elasticAgentIds: undefined,
+ endDate: undefined,
+ data: [
+ {
+ agents: ['agent-a', 'agent-b', 'agent-x'],
+ hosts: {
+ 'agent-a': { name: 'Host-agent-a' },
+ 'agent-b': { name: 'Host-agent-b' },
+ 'agent-x': { name: '' },
+ },
+ command: 'unisolate',
+ completedAt: undefined,
+ wasSuccessful: false,
+ errors: undefined,
+ id: '123',
+ isCompleted: false,
+ isExpired: true,
+ startedAt: '2022-04-27T16:08:47.449Z',
+ comment: doc?.EndpointActions.data.comment,
+ createdBy: doc?.user.id,
+ parameters: doc?.EndpointActions.data.parameters,
+ agentState: {
+ 'agent-a': {
+ completedAt: '2022-04-30T16:08:47.449Z',
+ isCompleted: true,
+ wasSuccessful: true,
+ errors: undefined,
+ },
+ 'agent-b': {
+ completedAt: undefined,
+ isCompleted: false,
+ wasSuccessful: false,
+ errors: undefined,
+ },
+ 'agent-x': {
+ completedAt: undefined,
+ isCompleted: false,
+ wasSuccessful: false,
+ errors: undefined,
+ },
+ },
+ },
+ ],
+ total: 1,
+ });
+ });
+
it('should call query with expected filters when querying for Action Request', async () => {
// mock metadataService.findHostMetadataForFleetAgents resolved value
(endpointAppContextService.getEndpointMetadataService as jest.Mock) = jest
diff --git a/x-pack/plugins/security_solution/server/endpoint/services/actions/action_list.ts b/x-pack/plugins/security_solution/server/endpoint/services/actions/action_list.ts
index 9e0a9a31d556a..d378085b71d1c 100644
--- a/x-pack/plugins/security_solution/server/endpoint/services/actions/action_list.ts
+++ b/x-pack/plugins/security_solution/server/endpoint/services/actions/action_list.ts
@@ -205,7 +205,7 @@ const getActionDetailsList = async ({
id: action.id,
agents: action.agents,
hosts: action.agents.reduce((acc, id) => {
- acc[id] = { name: agentsHostInfo[id] };
+ acc[id] = { name: agentsHostInfo[id] ?? '' };
return acc;
}, {}),
command: action.command,
diff --git a/x-pack/plugins/security_solution/server/endpoint/services/actions/mocks.ts b/x-pack/plugins/security_solution/server/endpoint/services/actions/mocks.ts
index d67807bf2cd83..80c7a5a6ff6c8 100644
--- a/x-pack/plugins/security_solution/server/endpoint/services/actions/mocks.ts
+++ b/x-pack/plugins/security_solution/server/endpoint/services/actions/mocks.ts
@@ -20,28 +20,30 @@ import {
ENDPOINT_ACTIONS_INDEX,
} from '../../../../common/endpoint/constants';
-export const createActionRequestsEsSearchResultsMock =
- (): estypes.SearchResponse => {
- const endpointActionGenerator = new EndpointActionGenerator('seed');
+export const createActionRequestsEsSearchResultsMock = (
+ agentIds?: string[]
+): estypes.SearchResponse => {
+ const endpointActionGenerator = new EndpointActionGenerator('seed');
- return endpointActionGenerator.toEsSearchResponse([
- endpointActionGenerator.generateActionEsHit({
- EndpointActions: { action_id: '123' },
- agent: { id: 'agent-a' },
- '@timestamp': '2022-04-27T16:08:47.449Z',
- }),
- ]);
- };
+ return endpointActionGenerator.toEsSearchResponse([
+ endpointActionGenerator.generateActionEsHit({
+ EndpointActions: { action_id: '123' },
+ agent: { id: agentIds ? agentIds : 'agent-a' },
+ '@timestamp': '2022-04-27T16:08:47.449Z',
+ }),
+ ]);
+};
-export const createActionResponsesEsSearchResultsMock = (): estypes.SearchResponse<
- LogsEndpointActionResponse | EndpointActionResponse
-> => {
+export const createActionResponsesEsSearchResultsMock = (
+ agentIds?: string[]
+): estypes.SearchResponse => {
const endpointActionGenerator = new EndpointActionGenerator('seed');
const fleetActionGenerator = new FleetActionGenerator('seed');
- return endpointActionGenerator.toEsSearchResponse<
- LogsEndpointActionResponse | EndpointActionResponse
- >([
+ let hitSource: Array<
+ | estypes.SearchHit
+ | estypes.SearchHit>
+ > = [
fleetActionGenerator.generateResponseEsHit({
action_id: '123',
agent_id: 'agent-a',
@@ -53,7 +55,31 @@ export const createActionResponsesEsSearchResultsMock = (): estypes.SearchRespon
EndpointActions: { action_id: '123' },
'@timestamp': '2022-04-30T16:08:47.449Z',
}),
- ]);
+ ];
+
+ if (agentIds?.length) {
+ const fleetResponses = agentIds.map((id) => {
+ return fleetActionGenerator.generateResponseEsHit({
+ action_id: '123',
+ agent_id: id,
+ error: '',
+ '@timestamp': '2022-04-30T16:08:47.449Z',
+ });
+ });
+
+ hitSource = [
+ ...fleetResponses,
+ endpointActionGenerator.generateResponseEsHit({
+ agent: { id: agentIds ? agentIds : 'agent-a' },
+ EndpointActions: { action_id: '123' },
+ '@timestamp': '2022-04-30T16:08:47.449Z',
+ }),
+ ];
+ }
+
+ return endpointActionGenerator.toEsSearchResponse<
+ LogsEndpointActionResponse | EndpointActionResponse
+ >(hitSource);
};
/**
diff --git a/x-pack/plugins/security_solution/server/lib/detection_engine/routes/rules/perform_bulk_action_route.ts b/x-pack/plugins/security_solution/server/lib/detection_engine/routes/rules/perform_bulk_action_route.ts
index 3c288184e0736..56d93a1ed0336 100644
--- a/x-pack/plugins/security_solution/server/lib/detection_engine/routes/rules/perform_bulk_action_route.ts
+++ b/x-pack/plugins/security_solution/server/lib/detection_engine/routes/rules/perform_bulk_action_route.ts
@@ -21,10 +21,10 @@ import {
MAX_RULES_TO_UPDATE_IN_PARALLEL,
RULES_TABLE_MAX_PAGE_SIZE,
} from '../../../../../common/constants';
-import { BulkAction } from '../../../../../common/detection_engine/schemas/common/schemas';
import {
performBulkActionSchema,
performBulkActionQuerySchema,
+ BulkAction,
} from '../../../../../common/detection_engine/schemas/request/perform_bulk_action_schema';
import type { SetupPlugins } from '../../../../plugin';
import type { SecuritySolutionPluginRouter } from '../../../../types';
diff --git a/x-pack/plugins/security_solution/server/lib/detection_engine/rule_types/eql/create_eql_alert_type.ts b/x-pack/plugins/security_solution/server/lib/detection_engine/rule_types/eql/create_eql_alert_type.ts
index abfdc5fe491a7..16db4e4955538 100644
--- a/x-pack/plugins/security_solution/server/lib/detection_engine/rule_types/eql/create_eql_alert_type.ts
+++ b/x-pack/plugins/security_solution/server/lib/detection_engine/rule_types/eql/create_eql_alert_type.ts
@@ -13,7 +13,7 @@ import type { EqlRuleParams } from '../../schemas/rule_schemas';
import { eqlRuleParams } from '../../schemas/rule_schemas';
import { eqlExecutor } from '../../signals/executors/eql';
import type { CreateRuleOptions, SecurityAlertType } from '../types';
-import { validateImmutable, validateIndexPatterns } from '../utils';
+import { validateIndexPatterns } from '../utils';
export const createEqlAlertType = (
createOptions: CreateRuleOptions
@@ -41,7 +41,6 @@ export const createEqlAlertType = (
* @returns mutatedRuleParams
*/
validateMutatedParams: (mutatedRuleParams) => {
- validateImmutable(mutatedRuleParams.immutable);
validateIndexPatterns(mutatedRuleParams.index);
return mutatedRuleParams;
diff --git a/x-pack/plugins/security_solution/server/lib/detection_engine/rule_types/indicator_match/create_indicator_match_alert_type.ts b/x-pack/plugins/security_solution/server/lib/detection_engine/rule_types/indicator_match/create_indicator_match_alert_type.ts
index 94fc6d78965bb..6a370b381acd1 100644
--- a/x-pack/plugins/security_solution/server/lib/detection_engine/rule_types/indicator_match/create_indicator_match_alert_type.ts
+++ b/x-pack/plugins/security_solution/server/lib/detection_engine/rule_types/indicator_match/create_indicator_match_alert_type.ts
@@ -13,7 +13,7 @@ import type { ThreatRuleParams } from '../../schemas/rule_schemas';
import { threatRuleParams } from '../../schemas/rule_schemas';
import { threatMatchExecutor } from '../../signals/executors/threat_match';
import type { CreateRuleOptions, SecurityAlertType } from '../types';
-import { validateImmutable, validateIndexPatterns } from '../utils';
+import { validateIndexPatterns } from '../utils';
export const createIndicatorMatchAlertType = (
createOptions: CreateRuleOptions
@@ -42,7 +42,6 @@ export const createIndicatorMatchAlertType = (
* @returns mutatedRuleParams
*/
validateMutatedParams: (mutatedRuleParams) => {
- validateImmutable(mutatedRuleParams.immutable);
validateIndexPatterns(mutatedRuleParams.index);
return mutatedRuleParams;
diff --git a/x-pack/plugins/security_solution/server/lib/detection_engine/rule_types/ml/create_ml_alert_type.ts b/x-pack/plugins/security_solution/server/lib/detection_engine/rule_types/ml/create_ml_alert_type.ts
index 926615fc8d176..c24e9c5af8d4f 100644
--- a/x-pack/plugins/security_solution/server/lib/detection_engine/rule_types/ml/create_ml_alert_type.ts
+++ b/x-pack/plugins/security_solution/server/lib/detection_engine/rule_types/ml/create_ml_alert_type.ts
@@ -13,7 +13,6 @@ import type { MachineLearningRuleParams } from '../../schemas/rule_schemas';
import { machineLearningRuleParams } from '../../schemas/rule_schemas';
import { mlExecutor } from '../../signals/executors/ml';
import type { CreateRuleOptions, SecurityAlertType } from '../types';
-import { validateImmutable } from '../utils';
export const createMlAlertType = (
createOptions: CreateRuleOptions
@@ -34,17 +33,6 @@ export const createMlAlertType = (
}
return validated;
},
- /**
- * validate rule params when rule is bulk edited (update and created in future as well)
- * returned params can be modified (useful in case of version increment)
- * @param mutatedRuleParams
- * @returns mutatedRuleParams
- */
- validateMutatedParams: (mutatedRuleParams) => {
- validateImmutable(mutatedRuleParams.immutable);
-
- return mutatedRuleParams;
- },
},
},
actionGroups: [
diff --git a/x-pack/plugins/security_solution/server/lib/detection_engine/rule_types/new_terms/create_new_terms_alert_type.ts b/x-pack/plugins/security_solution/server/lib/detection_engine/rule_types/new_terms/create_new_terms_alert_type.ts
index da37ddc49fce7..8a1f941a92f31 100644
--- a/x-pack/plugins/security_solution/server/lib/detection_engine/rule_types/new_terms/create_new_terms_alert_type.ts
+++ b/x-pack/plugins/security_solution/server/lib/detection_engine/rule_types/new_terms/create_new_terms_alert_type.ts
@@ -27,7 +27,7 @@ import {
buildNewTermsAgg,
} from './build_new_terms_aggregation';
import type { SignalSource } from '../../signals/types';
-import { validateImmutable, validateIndexPatterns } from '../utils';
+import { validateIndexPatterns } from '../utils';
import { parseDateString, validateHistoryWindowStart } from './utils';
import { addToSearchAfterReturn, createSearchAfterReturnType } from '../../signals/utils';
@@ -61,7 +61,6 @@ export const createNewTermsAlertType = (
* @returns mutatedRuleParams
*/
validateMutatedParams: (mutatedRuleParams) => {
- validateImmutable(mutatedRuleParams.immutable);
validateIndexPatterns(mutatedRuleParams.index);
return mutatedRuleParams;
diff --git a/x-pack/plugins/security_solution/server/lib/detection_engine/rule_types/query/create_query_alert_type.ts b/x-pack/plugins/security_solution/server/lib/detection_engine/rule_types/query/create_query_alert_type.ts
index 14e309a83c959..5a940ebe364c5 100644
--- a/x-pack/plugins/security_solution/server/lib/detection_engine/rule_types/query/create_query_alert_type.ts
+++ b/x-pack/plugins/security_solution/server/lib/detection_engine/rule_types/query/create_query_alert_type.ts
@@ -13,7 +13,7 @@ import type { QueryRuleParams } from '../../schemas/rule_schemas';
import { queryRuleParams } from '../../schemas/rule_schemas';
import { queryExecutor } from '../../signals/executors/query';
import type { CreateRuleOptions, SecurityAlertType } from '../types';
-import { validateImmutable, validateIndexPatterns } from '../utils';
+import { validateIndexPatterns } from '../utils';
export const createQueryAlertType = (
createOptions: CreateRuleOptions
): SecurityAlertType => {
@@ -40,7 +40,6 @@ export const createQueryAlertType = (
* @returns mutatedRuleParams
*/
validateMutatedParams: (mutatedRuleParams) => {
- validateImmutable(mutatedRuleParams.immutable);
validateIndexPatterns(mutatedRuleParams.index);
return mutatedRuleParams;
diff --git a/x-pack/plugins/security_solution/server/lib/detection_engine/rule_types/saved_query/create_saved_query_alert_type.ts b/x-pack/plugins/security_solution/server/lib/detection_engine/rule_types/saved_query/create_saved_query_alert_type.ts
index f8009220581e1..325d9adfb1bda 100644
--- a/x-pack/plugins/security_solution/server/lib/detection_engine/rule_types/saved_query/create_saved_query_alert_type.ts
+++ b/x-pack/plugins/security_solution/server/lib/detection_engine/rule_types/saved_query/create_saved_query_alert_type.ts
@@ -13,7 +13,7 @@ import type { CompleteRule, SavedQueryRuleParams } from '../../schemas/rule_sche
import { savedQueryRuleParams } from '../../schemas/rule_schemas';
import { queryExecutor } from '../../signals/executors/query';
import type { CreateRuleOptions, SecurityAlertType } from '../types';
-import { validateImmutable, validateIndexPatterns } from '../utils';
+import { validateIndexPatterns } from '../utils';
export const createSavedQueryAlertType = (
createOptions: CreateRuleOptions
): SecurityAlertType => {
@@ -40,7 +40,6 @@ export const createSavedQueryAlertType = (
* @returns mutatedRuleParams
*/
validateMutatedParams: (mutatedRuleParams) => {
- validateImmutable(mutatedRuleParams.immutable);
validateIndexPatterns(mutatedRuleParams.index);
return mutatedRuleParams;
diff --git a/x-pack/plugins/security_solution/server/lib/detection_engine/rule_types/threshold/create_threshold_alert_type.ts b/x-pack/plugins/security_solution/server/lib/detection_engine/rule_types/threshold/create_threshold_alert_type.ts
index cacc2f91a925f..1a419ddfd09c6 100644
--- a/x-pack/plugins/security_solution/server/lib/detection_engine/rule_types/threshold/create_threshold_alert_type.ts
+++ b/x-pack/plugins/security_solution/server/lib/detection_engine/rule_types/threshold/create_threshold_alert_type.ts
@@ -14,7 +14,7 @@ import { thresholdRuleParams } from '../../schemas/rule_schemas';
import { thresholdExecutor } from '../../signals/executors/threshold';
import type { ThresholdAlertState } from '../../signals/types';
import type { CreateRuleOptions, SecurityAlertType } from '../types';
-import { validateImmutable, validateIndexPatterns } from '../utils';
+import { validateIndexPatterns } from '../utils';
export const createThresholdAlertType = (
createOptions: CreateRuleOptions
@@ -42,7 +42,6 @@ export const createThresholdAlertType = (
* @returns mutatedRuleParams
*/
validateMutatedParams: (mutatedRuleParams) => {
- validateImmutable(mutatedRuleParams.immutable);
validateIndexPatterns(mutatedRuleParams.index);
return mutatedRuleParams;
diff --git a/x-pack/plugins/security_solution/server/lib/detection_engine/rule_types/utils/validate_mutated_params.ts b/x-pack/plugins/security_solution/server/lib/detection_engine/rule_types/utils/validate_mutated_params.ts
index 0aac2fc709588..f8a696f0c7f68 100644
--- a/x-pack/plugins/security_solution/server/lib/detection_engine/rule_types/utils/validate_mutated_params.ts
+++ b/x-pack/plugins/security_solution/server/lib/detection_engine/rule_types/utils/validate_mutated_params.ts
@@ -5,12 +5,6 @@
* 2.0.
*/
-export const validateImmutable = (immutable: boolean) => {
- if (immutable === true) {
- throw new Error("Elastic rule can't be edited");
- }
-};
-
export const validateIndexPatterns = (indices: string[] | undefined) => {
if (indices?.length === 0) {
throw new Error("Index patterns can't be empty");
diff --git a/x-pack/plugins/security_solution/server/lib/detection_engine/rules/bulk_actions/action_to_rules_client_operation.test.ts b/x-pack/plugins/security_solution/server/lib/detection_engine/rules/bulk_actions/action_to_rules_client_operation.test.ts
index 8646a79d3d070..54da8ec923245 100644
--- a/x-pack/plugins/security_solution/server/lib/detection_engine/rules/bulk_actions/action_to_rules_client_operation.test.ts
+++ b/x-pack/plugins/security_solution/server/lib/detection_engine/rules/bulk_actions/action_to_rules_client_operation.test.ts
@@ -5,34 +5,40 @@
* 2.0.
*/
-import { BulkActionEditType } from '../../../../../common/detection_engine/schemas/common/schemas';
+import { BulkActionEditType } from '../../../../../common/detection_engine/schemas/request/perform_bulk_action_schema';
import { bulkEditActionToRulesClientOperation } from './action_to_rules_client_operation';
describe('bulkEditActionToRulesClientOperation', () => {
- test('should transform tags bulk edit actions correctly f', () => {
+ test('should transform tags bulk edit actions correctly', () => {
expect(
bulkEditActionToRulesClientOperation({ type: BulkActionEditType.add_tags, value: ['test'] })
- ).toEqual({
- field: 'tags',
- operation: 'add',
- value: ['test'],
- });
+ ).toEqual([
+ {
+ field: 'tags',
+ operation: 'add',
+ value: ['test'],
+ },
+ ]);
});
expect(
bulkEditActionToRulesClientOperation({ type: BulkActionEditType.set_tags, value: ['test'] })
- ).toEqual({
- field: 'tags',
- operation: 'set',
- value: ['test'],
- });
+ ).toEqual([
+ {
+ field: 'tags',
+ operation: 'set',
+ value: ['test'],
+ },
+ ]);
expect(
bulkEditActionToRulesClientOperation({ type: BulkActionEditType.delete_tags, value: ['test'] })
- ).toEqual({
- field: 'tags',
- operation: 'delete',
- value: ['test'],
- });
+ ).toEqual([
+ {
+ field: 'tags',
+ operation: 'delete',
+ value: ['test'],
+ },
+ ]);
});
diff --git a/x-pack/plugins/security_solution/server/lib/detection_engine/rules/bulk_actions/action_to_rules_client_operation.ts b/x-pack/plugins/security_solution/server/lib/detection_engine/rules/bulk_actions/action_to_rules_client_operation.ts
index c75f7d0943e52..b462206aa8ff6 100644
--- a/x-pack/plugins/security_solution/server/lib/detection_engine/rules/bulk_actions/action_to_rules_client_operation.ts
+++ b/x-pack/plugins/security_solution/server/lib/detection_engine/rules/bulk_actions/action_to_rules_client_operation.ts
@@ -7,10 +7,26 @@
import type { BulkEditOperation } from '@kbn/alerting-plugin/server';
-import type { BulkActionEditForRuleAttributes } from '../../../../../common/detection_engine/schemas/common/schemas';
-import { BulkActionEditType } from '../../../../../common/detection_engine/schemas/common/schemas';
+import type { BulkActionEditForRuleAttributes } from '../../../../../common/detection_engine/schemas/request/perform_bulk_action_schema';
+import { BulkActionEditType } from '../../../../../common/detection_engine/schemas/request/perform_bulk_action_schema';
import { assertUnreachable } from '../../../../../common/utility_types';
+import { transformToAlertThrottle, transformToNotifyWhen } from '../utils';
+
+const getThrottleOperation = (throttle: string) =>
+ ({
+ field: 'throttle',
+ operation: 'set',
+ value: transformToAlertThrottle(throttle),
+ } as const);
+
+const getNotifyWhenOperation = (throttle: string) =>
+ ({
+ field: 'notifyWhen',
+ operation: 'set',
+ value: transformToNotifyWhen(throttle),
+ } as const);
+
/**
* converts bulk edit action to format of rulesClient.bulkEdit operation
* @param action BulkActionEditForRuleAttributes
@@ -18,31 +34,60 @@ import { assertUnreachable } from '../../../../../common/utility_types';
*/
export const bulkEditActionToRulesClientOperation = (
action: BulkActionEditForRuleAttributes
-): BulkEditOperation => {
+): BulkEditOperation[] => {
switch (action.type) {
// tags actions
case BulkActionEditType.add_tags:
- return {
- field: 'tags',
- operation: 'add',
- value: action.value,
- };
+ return [
+ {
+ field: 'tags',
+ operation: 'add',
+ value: action.value,
+ },
+ ];
case BulkActionEditType.delete_tags:
- return {
- field: 'tags',
- operation: 'delete',
- value: action.value,
- };
+ return [
+ {
+ field: 'tags',
+ operation: 'delete',
+ value: action.value,
+ },
+ ];
case BulkActionEditType.set_tags:
- return {
- field: 'tags',
- operation: 'set',
- value: action.value,
- };
+ return [
+ {
+ field: 'tags',
+ operation: 'set',
+ value: action.value,
+ },
+ ];
+
+ // rule actions
+ case BulkActionEditType.add_rule_actions:
+ return [
+ {
+ field: 'actions',
+ operation: 'add',
+ value: action.value.actions,
+ },
+ getThrottleOperation(action.value.throttle),
+ getNotifyWhenOperation(action.value.throttle),
+ ];
+
+ case BulkActionEditType.set_rule_actions:
+ return [
+ {
+ field: 'actions',
+ operation: 'set',
+ value: action.value.actions,
+ },
+ getThrottleOperation(action.value.throttle),
+ getNotifyWhenOperation(action.value.throttle),
+ ];
default:
- return assertUnreachable(action.type);
+ return assertUnreachable(action);
}
};
diff --git a/x-pack/plugins/security_solution/server/lib/detection_engine/rules/bulk_actions/rule_params_modifier.test.ts b/x-pack/plugins/security_solution/server/lib/detection_engine/rules/bulk_actions/rule_params_modifier.test.ts
index 592704842e6c2..8ea80e0fad430 100644
--- a/x-pack/plugins/security_solution/server/lib/detection_engine/rules/bulk_actions/rule_params_modifier.test.ts
+++ b/x-pack/plugins/security_solution/server/lib/detection_engine/rules/bulk_actions/rule_params_modifier.test.ts
@@ -6,7 +6,7 @@
*/
import { addItemsToArray, deleteItemsFromArray, ruleParamsModifier } from './rule_params_modifier';
-import { BulkActionEditType } from '../../../../../common/detection_engine/schemas/common/schemas';
+import { BulkActionEditType } from '../../../../../common/detection_engine/schemas/request/perform_bulk_action_schema';
import type { RuleAlertType } from '../types';
describe('addItemsToArray', () => {
@@ -38,9 +38,13 @@ describe('deleteItemsFromArray', () => {
});
describe('ruleParamsModifier', () => {
- const ruleParamsMock = { index: ['my-index-*'], version: 1 } as RuleAlertType['params'];
+ const ruleParamsMock = {
+ index: ['initial-index-*'],
+ version: 1,
+ immutable: false,
+ } as RuleAlertType['params'];
- test('should increment version', () => {
+ test('should increment version if rule is custom (immutable === false)', () => {
const editedRuleParams = ruleParamsModifier(ruleParamsMock, [
{
type: BulkActionEditType.add_index_patterns,
@@ -50,6 +54,16 @@ describe('ruleParamsModifier', () => {
expect(editedRuleParams).toHaveProperty('version', ruleParamsMock.version + 1);
});
+ test('should not increment version if rule is prebuilt (immutable === true)', () => {
+ const editedRuleParams = ruleParamsModifier({ ...ruleParamsMock, immutable: true }, [
+ {
+ type: BulkActionEditType.add_index_patterns,
+ value: ['my-index-*'],
+ },
+ ]);
+ expect(editedRuleParams).toHaveProperty('version', ruleParamsMock.version);
+ });
+
describe('index_patterns', () => {
describe('add_index_patterns action', () => {
test.each([
diff --git a/x-pack/plugins/security_solution/server/lib/detection_engine/rules/bulk_actions/rule_params_modifier.ts b/x-pack/plugins/security_solution/server/lib/detection_engine/rules/bulk_actions/rule_params_modifier.ts
index 2b3fb5de9ef79..14d49b14421b3 100644
--- a/x-pack/plugins/security_solution/server/lib/detection_engine/rules/bulk_actions/rule_params_modifier.ts
+++ b/x-pack/plugins/security_solution/server/lib/detection_engine/rules/bulk_actions/rule_params_modifier.ts
@@ -7,8 +7,8 @@
import type { RuleAlertType } from '../types';
-import type { BulkActionEditForRuleParams } from '../../../../../common/detection_engine/schemas/common/schemas';
-import { BulkActionEditType } from '../../../../../common/detection_engine/schemas/common/schemas';
+import type { BulkActionEditForRuleParams } from '../../../../../common/detection_engine/schemas/request/perform_bulk_action_schema';
+import { BulkActionEditType } from '../../../../../common/detection_engine/schemas/request/perform_bulk_action_schema';
import { invariant } from '../../../../../common/utils/invariant';
@@ -111,7 +111,10 @@ export const ruleParamsModifier = (
);
// increment version even if actions are empty, as attributes can be modified as well outside of ruleParamsModifier
- modifiedParams.version += 1;
+ // version must not be modified for immutable rule. Otherwise prebuilt rules upgrade flow will be broken
+ if (existingRuleParams.immutable === false) {
+ modifiedParams.version += 1;
+ }
return modifiedParams;
};
diff --git a/x-pack/plugins/security_solution/server/lib/detection_engine/rules/bulk_actions/split_bulk_edit_actions.test.ts b/x-pack/plugins/security_solution/server/lib/detection_engine/rules/bulk_actions/split_bulk_edit_actions.test.ts
index 0b7f540b4dcc3..46205c060be78 100644
--- a/x-pack/plugins/security_solution/server/lib/detection_engine/rules/bulk_actions/split_bulk_edit_actions.test.ts
+++ b/x-pack/plugins/security_solution/server/lib/detection_engine/rules/bulk_actions/split_bulk_edit_actions.test.ts
@@ -5,8 +5,8 @@
* 2.0.
*/
-import type { BulkActionEditPayload } from '../../../../../common/detection_engine/schemas/common/schemas';
-import { BulkActionEditType } from '../../../../../common/detection_engine/schemas/common/schemas';
+import type { BulkActionEditPayload } from '../../../../../common/detection_engine/schemas/request/perform_bulk_action_schema';
+import { BulkActionEditType } from '../../../../../common/detection_engine/schemas/request/perform_bulk_action_schema';
import { splitBulkEditActions } from './split_bulk_edit_actions';
diff --git a/x-pack/plugins/security_solution/server/lib/detection_engine/rules/bulk_actions/split_bulk_edit_actions.ts b/x-pack/plugins/security_solution/server/lib/detection_engine/rules/bulk_actions/split_bulk_edit_actions.ts
index e1ba96390d538..f9f16a7684294 100644
--- a/x-pack/plugins/security_solution/server/lib/detection_engine/rules/bulk_actions/split_bulk_edit_actions.ts
+++ b/x-pack/plugins/security_solution/server/lib/detection_engine/rules/bulk_actions/split_bulk_edit_actions.ts
@@ -5,12 +5,12 @@
* 2.0.
*/
+import { BulkActionEditType } from '../../../../../common/detection_engine/schemas/request/perform_bulk_action_schema';
import type {
BulkActionEditPayload,
BulkActionEditForRuleAttributes,
BulkActionEditForRuleParams,
-} from '../../../../../common/detection_engine/schemas/common/schemas';
-import { BulkActionEditType } from '../../../../../common/detection_engine/schemas/common/schemas';
+} from '../../../../../common/detection_engine/schemas/request/perform_bulk_action_schema';
/**
* Split bulk edit actions in 2 chunks: actions applied to params and
@@ -32,6 +32,8 @@ export const splitBulkEditActions = (actions: BulkActionEditPayload[]) => {
case BulkActionEditType.add_tags:
case BulkActionEditType.set_tags:
case BulkActionEditType.delete_tags:
+ case BulkActionEditType.add_rule_actions:
+ case BulkActionEditType.set_rule_actions:
acc.attributesActions.push(action);
break;
default:
diff --git a/x-pack/plugins/security_solution/server/lib/detection_engine/rules/bulk_actions/utils.ts b/x-pack/plugins/security_solution/server/lib/detection_engine/rules/bulk_actions/utils.ts
index 65a4af2308e0e..91cfe9544d550 100644
--- a/x-pack/plugins/security_solution/server/lib/detection_engine/rules/bulk_actions/utils.ts
+++ b/x-pack/plugins/security_solution/server/lib/detection_engine/rules/bulk_actions/utils.ts
@@ -4,7 +4,7 @@
* 2.0; you may not use this file except in compliance with the Elastic License
* 2.0.
*/
-import { BulkActionEditType } from '../../../../../common/detection_engine/schemas/common/schemas';
+import { BulkActionEditType } from '../../../../../common/detection_engine/schemas/request/perform_bulk_action_schema';
/**
* helper utility that defines whether bulk edit action is related to index patterns, i.e. one of:
diff --git a/x-pack/plugins/security_solution/server/lib/detection_engine/rules/bulk_actions/validations.ts b/x-pack/plugins/security_solution/server/lib/detection_engine/rules/bulk_actions/validations.ts
index 28793f9fe9c88..5252fd1982ff3 100644
--- a/x-pack/plugins/security_solution/server/lib/detection_engine/rules/bulk_actions/validations.ts
+++ b/x-pack/plugins/security_solution/server/lib/detection_engine/rules/bulk_actions/validations.ts
@@ -9,7 +9,8 @@ import type { Type as RuleType } from '@kbn/securitysolution-io-ts-alerting-type
import { invariant } from '../../../../../common/utils/invariant';
import { isMlRule } from '../../../../../common/machine_learning/helpers';
import { BulkActionsDryRunErrCode } from '../../../../../common/constants';
-import type { BulkActionEditPayload } from '../../../../../common/detection_engine/schemas/common/schemas';
+import type { BulkActionEditPayload } from '../../../../../common/detection_engine/schemas/request/perform_bulk_action_schema';
+import { BulkActionEditType } from '../../../../../common/detection_engine/schemas/request/perform_bulk_action_schema';
import type { RuleAlertType } from '../types';
import { isIndexPatternsBulkEditAction } from './utils';
import { throwDryRunError } from './dry_run';
@@ -24,6 +25,8 @@ interface BulkActionsValidationArgs {
interface BulkEditBulkActionsValidationArgs {
ruleType: RuleType;
mlAuthz: MlAuthz;
+ edit: BulkActionEditPayload[];
+ immutable: boolean;
}
interface DryRunBulkEditBulkActionsValidationArgs {
@@ -78,8 +81,26 @@ export const validateBulkDuplicateRule = async ({ rule, mlAuthz }: BulkActionsVa
export const validateBulkEditRule = async ({
ruleType,
mlAuthz,
+ edit,
+ immutable,
}: BulkEditBulkActionsValidationArgs) => {
await throwMlAuthError(mlAuthz, ruleType);
+
+ // if rule can't be edited error will be thrown
+ const canRuleBeEdited = !immutable || istEditApplicableToImmutableRule(edit);
+ await throwDryRunError(
+ () => invariant(canRuleBeEdited, "Elastic rule can't be edited"),
+ BulkActionsDryRunErrCode.IMMUTABLE
+ );
+};
+
+/**
+ * add_rule_actions, set_rule_actions can be applied to prebuilt/immutable rules
+ */
+const istEditApplicableToImmutableRule = (edit: BulkActionEditPayload[]): boolean => {
+ return edit.every(({ type }) =>
+ [BulkActionEditType.set_rule_actions, BulkActionEditType.add_rule_actions].includes(type)
+ );
};
/**
@@ -91,13 +112,12 @@ export const dryRunValidateBulkEditRule = async ({
edit,
mlAuthz,
}: DryRunBulkEditBulkActionsValidationArgs) => {
- await validateBulkEditRule({ ruleType: rule.params.type, mlAuthz });
-
- // if rule is immutable, it can't be edited
- await throwDryRunError(
- () => invariant(rule.params.immutable === false, "Elastic rule can't be edited"),
- BulkActionsDryRunErrCode.IMMUTABLE
- );
+ await validateBulkEditRule({
+ ruleType: rule.params.type,
+ mlAuthz,
+ edit,
+ immutable: rule.params.immutable,
+ });
// if rule is machine_learning, index pattern action can't be applied to it
await throwDryRunError(
diff --git a/x-pack/plugins/security_solution/server/lib/detection_engine/rules/bulk_edit_rules.ts b/x-pack/plugins/security_solution/server/lib/detection_engine/rules/bulk_edit_rules.ts
index 587d7d539caa6..b17b35fd010a8 100644
--- a/x-pack/plugins/security_solution/server/lib/detection_engine/rules/bulk_edit_rules.ts
+++ b/x-pack/plugins/security_solution/server/lib/detection_engine/rules/bulk_edit_rules.ts
@@ -5,15 +5,24 @@
* 2.0.
*/
-import type { RulesClient } from '@kbn/alerting-plugin/server';
-import type { BulkActionEditPayload } from '../../../../common/detection_engine/schemas/common';
+import pMap from 'p-map';
+import type { RulesClient, BulkEditError } from '@kbn/alerting-plugin/server';
+import type {
+ BulkActionEditPayload,
+ BulkActionEditPayloadRuleActions,
+} from '../../../../common/detection_engine/schemas/request/perform_bulk_action_schema';
import { enrichFilterWithRuleTypeMapping } from './enrich_filter_with_rule_type_mappings';
import type { MlAuthz } from '../../machine_learning/authz';
-
import { ruleParamsModifier } from './bulk_actions/rule_params_modifier';
import { splitBulkEditActions } from './bulk_actions/split_bulk_edit_actions';
import { validateBulkEditRule } from './bulk_actions/validations';
import { bulkEditActionToRulesClientOperation } from './bulk_actions/action_to_rules_client_operation';
+import {
+ NOTIFICATION_THROTTLE_NO_ACTIONS,
+ MAX_RULES_TO_UPDATE_IN_PARALLEL,
+} from '../../../../common/constants';
+import { BulkActionEditType } from '../../../../common/detection_engine/schemas/request/perform_bulk_action_schema';
+import { readRules } from './read_rules';
import type { RuleAlertType } from './types';
@@ -32,7 +41,7 @@ export interface BulkEditRulesArguments {
* @param BulkEditRulesArguments
* @returns edited rules and caught errors
*/
-export const bulkEditRules = ({
+export const bulkEditRules = async ({
rulesClient,
ids,
actions,
@@ -41,12 +50,75 @@ export const bulkEditRules = ({
}: BulkEditRulesArguments) => {
const { attributesActions, paramsActions } = splitBulkEditActions(actions);
- return rulesClient.bulkEdit({
+ const result = await rulesClient.bulkEdit({
...(ids ? { ids } : { filter: enrichFilterWithRuleTypeMapping(filter) }),
- operations: attributesActions.map(bulkEditActionToRulesClientOperation),
+ operations: attributesActions.map(bulkEditActionToRulesClientOperation).flat(),
paramsModifier: async (ruleParams: RuleAlertType['params']) => {
- await validateBulkEditRule({ mlAuthz, ruleType: ruleParams.type });
+ await validateBulkEditRule({
+ mlAuthz,
+ ruleType: ruleParams.type,
+ edit: actions,
+ immutable: ruleParams.immutable,
+ });
return ruleParamsModifier(ruleParams, paramsActions);
},
});
+
+ // rulesClient bulkEdit currently doesn't support bulk mute/unmute.
+ // this is a workaround to mitigate this,
+ // until https://github.com/elastic/kibana/issues/139084 is resolved
+ // if rule actions has been applied:
+ // - we go through each rule
+ // - mute/unmute if needed, refetch rule
+ // calling mute for rule needed only when rule was unmuted before and throttle value is NOTIFICATION_THROTTLE_NO_ACTIONS
+ // calling unmute needed only if rule was muted and throttle value is not NOTIFICATION_THROTTLE_NO_ACTIONS
+ const ruleActions = attributesActions.filter((rule): rule is BulkActionEditPayloadRuleActions =>
+ [BulkActionEditType.set_rule_actions, BulkActionEditType.add_rule_actions].includes(rule.type)
+ );
+
+ // bulk edit actions are applying in a historical order.
+ // So, we need to find a rule action that will be applied the last, to be able to check if rule should be muted/unmuted
+ const rulesAction = ruleActions.pop();
+
+ if (rulesAction) {
+ const muteOrUnmuteErrors: BulkEditError[] = [];
+ const rulesToMuteOrUnmute = await pMap(
+ result.rules,
+ async (rule) => {
+ try {
+ if (rule.muteAll && rulesAction.value.throttle !== NOTIFICATION_THROTTLE_NO_ACTIONS) {
+ await rulesClient.unmuteAll({ id: rule.id });
+ return (await readRules({ rulesClient, id: rule.id, ruleId: undefined })) ?? rule;
+ } else if (
+ !rule.muteAll &&
+ rulesAction.value.throttle === NOTIFICATION_THROTTLE_NO_ACTIONS
+ ) {
+ await rulesClient.muteAll({ id: rule.id });
+ return (await readRules({ rulesClient, id: rule.id, ruleId: undefined })) ?? rule;
+ }
+
+ return rule;
+ } catch (err) {
+ muteOrUnmuteErrors.push({
+ message: err.message,
+ rule: {
+ id: rule.id,
+ name: rule.name,
+ },
+ });
+
+ return null;
+ }
+ },
+ { concurrency: MAX_RULES_TO_UPDATE_IN_PARALLEL }
+ );
+
+ return {
+ ...result,
+ rules: rulesToMuteOrUnmute.filter((rule): rule is RuleAlertType => rule != null),
+ errors: [...result.errors, ...muteOrUnmuteErrors],
+ };
+ }
+
+ return result;
};
diff --git a/x-pack/plugins/stack_alerts/public/alert_types/es_query/rule_common_expressions/rule_common_expressions.tsx b/x-pack/plugins/stack_alerts/public/alert_types/es_query/rule_common_expressions/rule_common_expressions.tsx
index 2f2afd8953a7b..0c0fc9a9a3c0b 100644
--- a/x-pack/plugins/stack_alerts/public/alert_types/es_query/rule_common_expressions/rule_common_expressions.tsx
+++ b/x-pack/plugins/stack_alerts/public/alert_types/es_query/rule_common_expressions/rule_common_expressions.tsx
@@ -145,7 +145,7 @@ export const RuleCommonExpressions: React.FC = ({
onChangeExcludeHitsFromPreviousRun(event.target.checked);
}}
label={i18n.translate('xpack.stackAlerts.esQuery.ui.excludePreviousHitsExpression', {
- defaultMessage: 'Exclude the hits from previous rule runs',
+ defaultMessage: 'Exclude matches from previous runs',
})}
/>
diff --git a/x-pack/plugins/stack_alerts/public/alert_types/es_query/rule_common_expressions/threshold_help_popover.tsx b/x-pack/plugins/stack_alerts/public/alert_types/es_query/rule_common_expressions/threshold_help_popover.tsx
index b7a990f110a1e..1c465bd62f31f 100644
--- a/x-pack/plugins/stack_alerts/public/alert_types/es_query/rule_common_expressions/threshold_help_popover.tsx
+++ b/x-pack/plugins/stack_alerts/public/alert_types/es_query/rule_common_expressions/threshold_help_popover.tsx
@@ -6,14 +6,7 @@
*/
import React, { Component } from 'react';
-import {
- EuiButtonIcon,
- EuiPopover,
- EuiPopoverTitle,
- EuiText,
- EuiCallOut,
- EuiSpacer,
-} from '@elastic/eui';
+import { EuiButtonIcon, EuiPopover, EuiPopoverTitle, EuiText } from '@elastic/eui';
import { FormattedMessage } from '@kbn/i18n-react';
import { i18n } from '@kbn/i18n';
import { css } from '@emotion/react';
@@ -66,16 +59,16 @@ export class QueryThresholdHelpPopover extends Component<{}, State> {
}}
/>
+
+ Exclude matches from previous runs,
+ }}
+ />
+
-
-
);
}
diff --git a/x-pack/plugins/synthetics/server/legacy_uptime/lib/saved_objects/private_locations.ts b/x-pack/plugins/synthetics/server/legacy_uptime/lib/saved_objects/private_locations.ts
index b90fa82a65eb8..c640340b65a26 100644
--- a/x-pack/plugins/synthetics/server/legacy_uptime/lib/saved_objects/private_locations.ts
+++ b/x-pack/plugins/synthetics/server/legacy_uptime/lib/saved_objects/private_locations.ts
@@ -11,7 +11,7 @@ import {
SavedObjectsType,
} from '@kbn/core/server';
import { privateLocationsSavedObjectName } from '../../../../common/saved_objects/private_locations';
-import { SyntheticsPrivateLocations } from '../../../../common/runtime_types';
+import { PrivateLocation, SyntheticsPrivateLocations } from '../../../../common/runtime_types';
export const privateLocationsSavedObjectId = 'synthetics-privates-locations-singleton';
export const privateLocationsSavedObject: SavedObjectsType = {
@@ -32,7 +32,9 @@ export const privateLocationsSavedObject: SavedObjectsType = {
},
};
-export const getSyntheticsPrivateLocations = async (client: SavedObjectsClientContract) => {
+export const getSyntheticsPrivateLocations = async (
+ client: SavedObjectsClientContract
+): Promise => {
try {
const obj = await client.get(
privateLocationsSavedObject.name,
diff --git a/x-pack/plugins/synthetics/server/routes/monitor_cruds/add_monitor.ts b/x-pack/plugins/synthetics/server/routes/monitor_cruds/add_monitor.ts
index 011b5f853a47b..b7caffa1530a6 100644
--- a/x-pack/plugins/synthetics/server/routes/monitor_cruds/add_monitor.ts
+++ b/x-pack/plugins/synthetics/server/routes/monitor_cruds/add_monitor.ts
@@ -7,10 +7,11 @@
import { schema } from '@kbn/config-schema';
import {
SavedObject,
- SavedObjectsErrorHelpers,
SavedObjectsClientContract,
KibanaRequest,
+ SavedObjectsErrorHelpers,
} from '@kbn/core/server';
+import { v4 as uuidV4 } from 'uuid';
import { SyntheticsMonitorClient } from '../../synthetics_service/synthetics_monitor/synthetics_monitor_client';
import {
ConfigKey,
@@ -61,101 +62,130 @@ export const addSyntheticsMonitorRoute: SyntheticsRestApiRouteFactory = () => ({
return response.badRequest({ body: { message, attributes: { details, ...payload } } });
}
- let newMonitor: SavedObject | null = null;
-
try {
- newMonitor = await savedObjectsClient.create(
- syntheticsMonitorType,
- formatSecrets({
- ...monitorWithDefaults,
- revision: 1,
- }),
- id
- ? {
- id,
- overwrite: true,
- }
- : undefined
- );
+ const { errors, newMonitor } = await syncNewMonitor({
+ normalizedMonitor: monitorWithDefaults,
+ monitor,
+ server,
+ syntheticsMonitorClient,
+ savedObjectsClient,
+ request,
+ id,
+ });
+
+ if (errors && errors.length > 0) {
+ return response.ok({
+ body: {
+ message: 'error pushing monitor to the service',
+ attributes: { errors },
+ id: newMonitor.id,
+ },
+ });
+ }
+
+ return response.ok({ body: newMonitor });
} catch (getErr) {
if (SavedObjectsErrorHelpers.isForbiddenError(getErr)) {
return response.forbidden({ body: getErr });
}
- }
- if (!newMonitor) {
return response.customError({
body: { message: 'Unable to create monitor' },
statusCode: 500,
});
}
-
- const errors = await syncNewMonitor({
- monitor,
- monitorSavedObject: newMonitor,
- server,
- syntheticsMonitorClient,
- savedObjectsClient,
- request,
- });
-
- if (errors && errors.length > 0) {
- return response.ok({
- body: {
- message: 'error pushing monitor to the service',
- attributes: { errors },
- id: newMonitor.id,
- },
- });
- }
-
- return response.ok({ body: newMonitor });
},
});
+export const createNewSavedObjectMonitor = async ({
+ id,
+ savedObjectsClient,
+ normalizedMonitor,
+}: {
+ id?: string;
+ savedObjectsClient: SavedObjectsClientContract;
+ normalizedMonitor: SyntheticsMonitor;
+}) => {
+ return await savedObjectsClient.create(
+ syntheticsMonitorType,
+ formatSecrets({
+ ...normalizedMonitor,
+ revision: 1,
+ }),
+ id
+ ? {
+ id,
+ overwrite: true,
+ }
+ : undefined
+ );
+};
+
export const syncNewMonitor = async ({
+ id,
monitor,
- monitorSavedObject,
server,
syntheticsMonitorClient,
savedObjectsClient,
request,
+ normalizedMonitor,
}: {
+ id?: string;
monitor: SyntheticsMonitor;
- monitorSavedObject: SavedObject;
+ normalizedMonitor: SyntheticsMonitor;
server: UptimeServerSetup;
syntheticsMonitorClient: SyntheticsMonitorClient;
savedObjectsClient: SavedObjectsClientContract;
request: KibanaRequest;
}) => {
+ const newMonitorId = id ?? uuidV4();
+
+ let monitorSavedObject: SavedObject | null = null;
+
try {
- const errors = await syntheticsMonitorClient.addMonitor(
+ const newMonitorPromise = createNewSavedObjectMonitor({
+ normalizedMonitor,
+ id: newMonitorId,
+ savedObjectsClient,
+ });
+
+ const syncErrorsPromise = syntheticsMonitorClient.addMonitor(
monitor as MonitorFields,
- monitorSavedObject.id,
+ newMonitorId,
request,
savedObjectsClient
);
+ const [monitorSavedObjectN, syncErrors] = await Promise.all([
+ newMonitorPromise,
+ syncErrorsPromise,
+ ]);
+
+ monitorSavedObject = monitorSavedObjectN;
+
sendTelemetryEvents(
server.logger,
server.telemetry,
formatTelemetryEvent({
+ errors: syncErrors,
monitor: monitorSavedObject,
- errors,
isInlineScript: Boolean((monitor as MonitorFields)[ConfigKey.SOURCE_INLINE]),
kibanaVersion: server.kibanaVersion,
})
);
- return errors;
+ return { errors: syncErrors, newMonitor: monitorSavedObject };
} catch (e) {
- await deleteMonitor({
- savedObjectsClient,
- server,
- monitorId: monitorSavedObject.id,
- syntheticsMonitorClient,
- request,
- });
+ if (monitorSavedObject?.id) {
+ await deleteMonitor({
+ savedObjectsClient,
+ server,
+ monitorId: newMonitorId,
+ syntheticsMonitorClient,
+ request,
+ });
+ }
+
throw e;
}
};
diff --git a/x-pack/plugins/synthetics/server/routes/monitor_cruds/delete_monitor.ts b/x-pack/plugins/synthetics/server/routes/monitor_cruds/delete_monitor.ts
index 2313ca548ed29..13b43004706ed 100644
--- a/x-pack/plugins/synthetics/server/routes/monitor_cruds/delete_monitor.ts
+++ b/x-pack/plugins/synthetics/server/routes/monitor_cruds/delete_monitor.ts
@@ -28,7 +28,7 @@ import {
sendTelemetryEvents,
formatTelemetryDeleteEvent,
} from '../telemetry/monitor_upgrade_sender';
-import { normalizeSecrets } from '../../synthetics_service/utils/secrets';
+import { formatSecrets, normalizeSecrets } from '../../synthetics_service/utils/secrets';
import type { UptimeServerSetup } from '../../legacy_uptime/lib/adapters/framework';
export const deleteSyntheticsMonitorRoute: SyntheticsRestApiRouteFactory = () => ({
@@ -89,6 +89,7 @@ export const deleteMonitor = async ({
}) => {
const { logger, telemetry, kibanaVersion, encryptedSavedObjects } = server;
const encryptedSavedObjectsClient = encryptedSavedObjects.getClient();
+ let normalizedMonitor;
try {
const encryptedMonitor = await savedObjectsClient.get(
syntheticsMonitorType,
@@ -104,9 +105,9 @@ export const deleteMonitor = async ({
}
);
- const normalizedMonitor = normalizeSecrets(monitor);
+ normalizedMonitor = normalizeSecrets(monitor);
- const errors = await syntheticsMonitorClient.deleteMonitor(
+ const deleteSyncPromise = syntheticsMonitorClient.deleteMonitor(
{
...normalizedMonitor.attributes,
id:
@@ -116,7 +117,9 @@ export const deleteMonitor = async ({
request,
savedObjectsClient
);
- await savedObjectsClient.delete(syntheticsMonitorType, monitorId);
+ const deletePromise = savedObjectsClient.delete(syntheticsMonitorType, monitorId);
+
+ const [errors] = await Promise.all([deleteSyncPromise, deletePromise]);
sendTelemetryEvents(
logger,
@@ -132,6 +135,36 @@ export const deleteMonitor = async ({
return errors;
} catch (e) {
+ if (normalizedMonitor) {
+ await restoreDeletedMonitor({
+ monitorId,
+ normalizedMonitor: formatSecrets({
+ ...normalizedMonitor.attributes,
+ }),
+ savedObjectsClient,
+ });
+ }
throw e;
}
};
+
+const restoreDeletedMonitor = async ({
+ monitorId,
+ savedObjectsClient,
+ normalizedMonitor,
+}: {
+ monitorId: string;
+ normalizedMonitor: SyntheticsMonitorWithSecrets;
+ savedObjectsClient: SavedObjectsClientContract;
+}) => {
+ try {
+ await savedObjectsClient.get(syntheticsMonitorType, monitorId);
+ } catch (e) {
+ if (SavedObjectsErrorHelpers.isNotFoundError(e)) {
+ await savedObjectsClient.create(syntheticsMonitorType, normalizedMonitor, {
+ id: monitorId,
+ overwrite: true,
+ });
+ }
+ }
+};
diff --git a/x-pack/plugins/synthetics/server/routes/monitor_cruds/edit_monitor.test.ts b/x-pack/plugins/synthetics/server/routes/monitor_cruds/edit_monitor.test.ts
index 649f0ec4a85db..b1e1ac4551fef 100644
--- a/x-pack/plugins/synthetics/server/routes/monitor_cruds/edit_monitor.test.ts
+++ b/x-pack/plugins/synthetics/server/routes/monitor_cruds/edit_monitor.test.ts
@@ -7,12 +7,7 @@
import { loggerMock } from '@kbn/logging-mocks';
import { syncEditedMonitor } from './edit_monitor';
-import {
- SavedObjectsUpdateResponse,
- SavedObject,
- SavedObjectsClientContract,
- KibanaRequest,
-} from '@kbn/core/server';
+import { SavedObject, SavedObjectsClientContract, KibanaRequest } from '@kbn/core/server';
import {
EncryptedSyntheticsMonitor,
SyntheticsMonitor,
@@ -21,6 +16,7 @@ import {
import { UptimeServerSetup } from '../../legacy_uptime/lib/adapters';
import { SyntheticsService } from '../../synthetics_service/synthetics_service';
import { SyntheticsMonitorClient } from '../../synthetics_service/synthetics_monitor/synthetics_monitor_client';
+import { formatSecrets } from '../../synthetics_service/utils';
jest.mock('../telemetry/monitor_upgrade_sender', () => ({
sendTelemetryEvents: jest.fn(),
@@ -33,7 +29,11 @@ describe('syncEditedMonitor', () => {
const serverMock: UptimeServerSetup = {
uptimeEsClient: { search: jest.fn() },
kibanaVersion: null,
- authSavedObjectsClient: { bulkUpdate: jest.fn(), get: jest.fn(), update: jest.fn() },
+ authSavedObjectsClient: {
+ bulkUpdate: jest.fn(),
+ get: jest.fn(),
+ update: jest.fn(),
+ },
logger,
config: {
service: {
@@ -77,9 +77,6 @@ describe('syncEditedMonitor', () => {
id: 'saved-obj-id',
attributes: { name: editedMonitor.name },
} as SavedObject;
- const editedMonitorSavedObject = {
- id: 'saved-obj-id',
- } as SavedObjectsUpdateResponse;
const syntheticsService = new SyntheticsService(serverMock);
@@ -89,8 +86,8 @@ describe('syncEditedMonitor', () => {
it('includes the isEdit flag', async () => {
await syncEditedMonitor({
- editedMonitor,
- editedMonitorSavedObject,
+ normalizedMonitor: editedMonitor,
+ monitorWithRevision: formatSecrets(editedMonitor),
previousMonitor,
decryptedPreviousMonitor:
previousMonitor as unknown as SavedObject,
@@ -106,5 +103,13 @@ describe('syncEditedMonitor', () => {
id: 'saved-obj-id',
})
);
+
+ expect(serverMock.authSavedObjectsClient?.update).toHaveBeenCalledWith(
+ 'synthetics-monitor',
+ 'saved-obj-id',
+ expect.objectContaining({
+ enabled: true,
+ })
+ );
});
});
diff --git a/x-pack/plugins/synthetics/server/routes/monitor_cruds/edit_monitor.ts b/x-pack/plugins/synthetics/server/routes/monitor_cruds/edit_monitor.ts
index a5d8365d0de2a..832c4322a2866 100644
--- a/x-pack/plugins/synthetics/server/routes/monitor_cruds/edit_monitor.ts
+++ b/x-pack/plugins/synthetics/server/routes/monitor_cruds/edit_monitor.ts
@@ -92,26 +92,16 @@ export const editSyntheticsMonitorRoute: SyntheticsRestApiRouteFactory = () => (
revision: (previousMonitor.attributes[ConfigKey.REVISION] || 0) + 1,
};
const formattedMonitor = formatSecrets(monitorWithRevision);
- const isMultiStepMonitor =
- monitor.type === 'browser' &&
- monitor[ConfigKey.FORM_MONITOR_TYPE] !== FormMonitorType.SINGLE;
- const editedMonitorSavedObject: SavedObjectsUpdateResponse =
- await savedObjectsClient.update(
- syntheticsMonitorType,
- monitorId,
- isMultiStepMonitor ? { ...formattedMonitor, urls: '' } : formattedMonitor
- );
-
- const errors = await syncEditedMonitor({
+ const { errors, editedMonitor: editedMonitorSavedObject } = await syncEditedMonitor({
server,
- editedMonitor,
- editedMonitorSavedObject,
previousMonitor,
decryptedPreviousMonitor,
syntheticsMonitorClient,
savedObjectsClient,
request,
+ normalizedMonitor: editedMonitor,
+ monitorWithRevision: formattedMonitor,
});
// Return service sync errors in OK response
@@ -134,8 +124,8 @@ export const editSyntheticsMonitorRoute: SyntheticsRestApiRouteFactory = () => (
});
export const syncEditedMonitor = async ({
- editedMonitor,
- editedMonitorSavedObject,
+ normalizedMonitor,
+ monitorWithRevision,
previousMonitor,
decryptedPreviousMonitor,
server,
@@ -143,8 +133,8 @@ export const syncEditedMonitor = async ({
savedObjectsClient,
request,
}: {
- editedMonitor: SyntheticsMonitor;
- editedMonitorSavedObject: SavedObjectsUpdateResponse;
+ normalizedMonitor: SyntheticsMonitor;
+ monitorWithRevision: SyntheticsMonitorWithSecrets;
previousMonitor: SavedObject;
decryptedPreviousMonitor: SavedObject;
server: UptimeServerSetup;
@@ -153,33 +143,47 @@ export const syncEditedMonitor = async ({
request: KibanaRequest;
}) => {
try {
- const errors = await syntheticsMonitorClient.editMonitor(
- editedMonitor as MonitorFields,
- editedMonitorSavedObject.id,
+ const editedSOPromise = savedObjectsClient.update(
+ syntheticsMonitorType,
+ previousMonitor.id,
+ monitorWithRevision.type === 'browser' &&
+ monitorWithRevision[ConfigKey.FORM_MONITOR_TYPE] !== FormMonitorType.SINGLE
+ ? { ...monitorWithRevision, urls: '' }
+ : monitorWithRevision
+ );
+
+ const editSyncPromise = syntheticsMonitorClient.editMonitor(
+ normalizedMonitor as MonitorFields,
+ previousMonitor.id,
request,
savedObjectsClient
);
+ const [editedMonitorSavedObject, errors] = await Promise.all([
+ editedSOPromise,
+ editSyncPromise,
+ ]);
+
sendTelemetryEvents(
server.logger,
server.telemetry,
formatTelemetryUpdateEvent(
- editedMonitorSavedObject,
+ editedMonitorSavedObject as SavedObjectsUpdateResponse,
previousMonitor,
server.kibanaVersion,
- Boolean((editedMonitor as MonitorFields)[ConfigKey.SOURCE_INLINE]),
+ Boolean((normalizedMonitor as MonitorFields)[ConfigKey.SOURCE_INLINE]),
errors
)
);
- return errors;
+ return { errors, editedMonitor: editedMonitorSavedObject };
} catch (e) {
server.logger.error(
`Unable to update Synthetics monitor ${decryptedPreviousMonitor.attributes[ConfigKey.NAME]}`
);
await savedObjectsClient.update(
syntheticsMonitorType,
- editedMonitorSavedObject.id,
+ previousMonitor.id,
decryptedPreviousMonitor.attributes
);
diff --git a/x-pack/plugins/synthetics/server/synthetics_service/project_monitor_formatter.ts b/x-pack/plugins/synthetics/server/synthetics_service/project_monitor_formatter.ts
index 3067ee6319052..c96b06886a306 100644
--- a/x-pack/plugins/synthetics/server/synthetics_service/project_monitor_formatter.ts
+++ b/x-pack/plugins/synthetics/server/synthetics_service/project_monitor_formatter.ts
@@ -17,7 +17,6 @@ import { SyntheticsMonitorClient } from './synthetics_monitor/synthetics_monitor
import {
BrowserFields,
ConfigKey,
- MonitorFields,
SyntheticsMonitorWithSecrets,
EncryptedSyntheticsMonitor,
ServiceLocationErrors,
@@ -230,17 +229,10 @@ export class ProjectMonitorFormatter {
};
private createMonitor = async (normalizedMonitor: BrowserFields) => {
- const newMonitor = await this.savedObjectsClient.create(
- syntheticsMonitorType,
- formatSecrets({
- ...normalizedMonitor,
- revision: 1,
- })
- );
await syncNewMonitor({
- server: this.server,
+ normalizedMonitor,
monitor: normalizedMonitor,
- monitorSavedObject: newMonitor,
+ server: this.server,
syntheticsMonitorClient: this.syntheticsMonitorClient,
savedObjectsClient: this.savedObjectsClient,
request: this.request,
@@ -273,20 +265,11 @@ export class ProjectMonitorFormatter {
? (previousMonitor.attributes[ConfigKey.REVISION] || 0) + 1
: previousMonitor.attributes[ConfigKey.REVISION],
});
- const editedMonitor: SavedObjectsUpdateResponse =
- await this.savedObjectsClient.update(
- syntheticsMonitorType,
- previousMonitor.id,
- {
- ...monitorWithRevision,
- urls: '',
- }
- );
if (hasMonitorBeenEdited) {
- await syncEditedMonitor({
- editedMonitor: normalizedMonitor,
- editedMonitorSavedObject: editedMonitor,
+ const { editedMonitor } = await syncEditedMonitor({
+ normalizedMonitor,
+ monitorWithRevision,
previousMonitor,
decryptedPreviousMonitor,
server: this.server,
@@ -294,9 +277,10 @@ export class ProjectMonitorFormatter {
savedObjectsClient: this.savedObjectsClient,
request: this.request,
});
+ return { editedMonitor, errors: [] };
}
- return { editedMonitor, errors: [] };
+ return { errors: [], editedMonitor: decryptedPreviousMonitor };
};
private handleStaleMonitors = async () => {
diff --git a/x-pack/plugins/translations/translations/fr-FR.json b/x-pack/plugins/translations/translations/fr-FR.json
index f8c9866f3a13b..476901aec65af 100644
--- a/x-pack/plugins/translations/translations/fr-FR.json
+++ b/x-pack/plugins/translations/translations/fr-FR.json
@@ -30322,7 +30322,6 @@
"xpack.stackAlerts.esQuery.ui.testQuery": "Tester la recherche",
"xpack.stackAlerts.esQuery.ui.testQueryIsExecuted": "La requête a été exécutée.",
"xpack.stackAlerts.esQuery.ui.thresholdHelp.ariaLabel": "Aide",
- "xpack.stackAlerts.esQuery.ui.thresholdHelp.duplicateMatches": "Si la fenêtre de temps est supérieure à l'intervalle de vérification et qu'un document correspond à la requête dans plusieurs exécutions, il n'est utilisé que dans le premier calcul du seuil.",
"xpack.stackAlerts.esQuery.ui.thresholdHelp.threshold": "Chaque fois que la règle s'exécute, elle vérifie si le nombre de documents qui correspondent à votre requête atteint ce seuil.",
"xpack.stackAlerts.esQuery.ui.thresholdHelp.title": "Définir le seuil et la fenêtre de temps",
"xpack.stackAlerts.esQuery.ui.validation.error.greaterThenThreshold0Text": "Seuil 1 doit être supérieur à Seuil 0.",
diff --git a/x-pack/plugins/translations/translations/ja-JP.json b/x-pack/plugins/translations/translations/ja-JP.json
index 28947bc3c61bc..f000678d323b0 100644
--- a/x-pack/plugins/translations/translations/ja-JP.json
+++ b/x-pack/plugins/translations/translations/ja-JP.json
@@ -30298,7 +30298,6 @@
"xpack.stackAlerts.esQuery.ui.testQuery": "クエリのテスト",
"xpack.stackAlerts.esQuery.ui.testQueryIsExecuted": "クエリが実行されます。",
"xpack.stackAlerts.esQuery.ui.thresholdHelp.ariaLabel": "ヘルプ",
- "xpack.stackAlerts.esQuery.ui.thresholdHelp.duplicateMatches": "時間枠がチェック間隔より長く、ドキュメントが複数の実行でクエリと一致する場合、最初のしきい値計算でのみ使用されます。",
"xpack.stackAlerts.esQuery.ui.thresholdHelp.threshold": "ルールが実行されるたびに、クエリと一致するドキュメントの数がこのしきい値を満たすかどうかが確認されます。",
"xpack.stackAlerts.esQuery.ui.thresholdHelp.title": "しきい値と時間枠を設定",
"xpack.stackAlerts.esQuery.ui.validation.error.greaterThenThreshold0Text": "しきい値1はしきい値0より大きくなければなりません。",
diff --git a/x-pack/plugins/translations/translations/zh-CN.json b/x-pack/plugins/translations/translations/zh-CN.json
index 929b2e2fa492c..c3f3edc74fda2 100644
--- a/x-pack/plugins/translations/translations/zh-CN.json
+++ b/x-pack/plugins/translations/translations/zh-CN.json
@@ -30330,7 +30330,6 @@
"xpack.stackAlerts.esQuery.ui.testQuery": "测试查询",
"xpack.stackAlerts.esQuery.ui.testQueryIsExecuted": "已执行查询。",
"xpack.stackAlerts.esQuery.ui.thresholdHelp.ariaLabel": "帮助",
- "xpack.stackAlerts.esQuery.ui.thresholdHelp.duplicateMatches": "如果时间窗口大于检查时间间隔且文档在多次运行时与查询匹配,则仅将其用在第一次阈值计算期间。",
"xpack.stackAlerts.esQuery.ui.thresholdHelp.threshold": "每次运行规则时,都会检查与查询匹配的文档数目是否与此阈值相符。",
"xpack.stackAlerts.esQuery.ui.thresholdHelp.title": "设置阈值和时间窗口",
"xpack.stackAlerts.esQuery.ui.validation.error.greaterThenThreshold0Text": "阈值 1 必须 > 阈值 0。",
diff --git a/x-pack/test/detection_engine_api_integration/security_and_spaces/group1/perform_bulk_action.ts b/x-pack/test/detection_engine_api_integration/security_and_spaces/group1/perform_bulk_action.ts
index 4742eca71f9b0..4d4bda5e6b4e0 100644
--- a/x-pack/test/detection_engine_api_integration/security_and_spaces/group1/perform_bulk_action.ts
+++ b/x-pack/test/detection_engine_api_integration/security_and_spaces/group1/perform_bulk_action.ts
@@ -10,11 +10,14 @@ import expect from '@kbn/expect';
import {
DETECTION_ENGINE_RULES_BULK_ACTION,
DETECTION_ENGINE_RULES_URL,
+ NOTIFICATION_THROTTLE_NO_ACTIONS,
+ NOTIFICATION_THROTTLE_RULE,
} from '@kbn/security-solution-plugin/common/constants';
+
import {
BulkAction,
BulkActionEditType,
-} from '@kbn/security-solution-plugin/common/detection_engine/schemas/common/schemas';
+} from '@kbn/security-solution-plugin/common/detection_engine/schemas/request/perform_bulk_action_schema';
import { RulesSchema } from '@kbn/security-solution-plugin/common/detection_engine/schemas/response';
import { FtrProviderContext } from '../../common/ftr_provider_context';
import {
@@ -30,6 +33,7 @@ import {
getLegacyActionSO,
installPrePackagedRules,
getSimpleMlRule,
+ getWebHookAction,
} from '../../utils';
// eslint-disable-next-line import/no-default-export
@@ -43,6 +47,31 @@ export default ({ getService }: FtrProviderContext): void => {
const fetchRule = (ruleId: string) =>
supertest.get(`${DETECTION_ENGINE_RULES_URL}?rule_id=${ruleId}`).set('kbn-xsrf', 'true');
+ const fetchPrebuiltRule = async () => {
+ const { body: findBody } = await supertest
+ .get(
+ `${DETECTION_ENGINE_RULES_URL}/_find?per_page=1&filter=alert.attributes.params.immutable: true`
+ )
+ .set('kbn-xsrf', 'true');
+
+ return findBody.data[0];
+ };
+
+ /**
+ * allows to get access to internal property: notifyWhen
+ */
+ const fetchRuleByAlertApi = (ruleId: string) =>
+ supertest.get(`/api/alerting/rule/${ruleId}`).set('kbn-xsrf', 'true');
+
+ const createWebHookAction = async () =>
+ (
+ await supertest
+ .post('/api/actions/action')
+ .set('kbn-xsrf', 'true')
+ .send(getWebHookAction())
+ .expect(200)
+ ).body;
+
describe('perform_bulk_action', () => {
beforeEach(async () => {
await createSignalsIndex(supertest, log);
@@ -905,24 +934,50 @@ export default ({ getService }: FtrProviderContext): void => {
expect(rule.timeline_title).to.be(undefined);
});
- it('should return error when trying to bulk edit immutable rule', async () => {
- await installPrePackagedRules(supertest, log);
- const { body: findBody } = await supertest
- .get(
- `${DETECTION_ENGINE_RULES_URL}/_find?per_page=1&filter=alert.attributes.params.immutable: true`
- )
- .set('kbn-xsrf', 'true')
- .send();
- const immutableRule = findBody.data[0];
+ it('should return error if index patterns action is applied to machine learning rule', async () => {
+ const mlRule = await createRule(supertest, log, getSimpleMlRule());
const { body } = await postBulkAction()
.send({
- ids: [immutableRule.id],
+ ids: [mlRule.id],
action: BulkAction.edit,
[BulkAction.edit]: [
{
- type: BulkActionEditType.add_tags,
- value: ['new-tag'],
+ type: BulkActionEditType.add_index_patterns,
+ value: ['index-*'],
+ },
+ ],
+ })
+ .expect(500);
+
+ expect(body.attributes.summary).to.eql({ failed: 1, succeeded: 0, total: 1 });
+ expect(body.attributes.errors[0]).to.eql({
+ message:
+ "Index patterns can't be added. Machine learning rule doesn't have index patterns property",
+ status_code: 500,
+ rules: [
+ {
+ id: mlRule.id,
+ name: mlRule.name,
+ },
+ ],
+ });
+ });
+
+ it('should return error if all index patterns removed from a rule', async () => {
+ const rule = await createRule(supertest, log, {
+ ...getSimpleRule(),
+ index: ['simple-index-*'],
+ });
+
+ const { body } = await postBulkAction()
+ .send({
+ ids: [rule.id],
+ action: BulkAction.edit,
+ [BulkAction.edit]: [
+ {
+ type: BulkActionEditType.delete_index_patterns,
+ value: ['simple-index-*'],
},
],
})
@@ -930,12 +985,12 @@ export default ({ getService }: FtrProviderContext): void => {
expect(body.attributes.summary).to.eql({ failed: 1, succeeded: 0, total: 1 });
expect(body.attributes.errors[0]).to.eql({
- message: "Mutated params invalid: Elastic rule can't be edited",
+ message: "Mutated params invalid: Index patterns can't be empty",
status_code: 500,
rules: [
{
- id: immutableRule.id,
- name: immutableRule.name,
+ id: rule.id,
+ name: rule.name,
},
],
});
@@ -964,6 +1019,642 @@ export default ({ getService }: FtrProviderContext): void => {
expect(updatedRule.version).to.be(rule.version + 1);
});
+
+ describe('prebuilt rules', () => {
+ const cases = [
+ {
+ type: BulkActionEditType.add_tags,
+ value: ['new-tag'],
+ },
+ {
+ type: BulkActionEditType.set_tags,
+ value: ['new-tag'],
+ },
+ {
+ type: BulkActionEditType.delete_tags,
+ value: ['new-tag'],
+ },
+ {
+ type: BulkActionEditType.add_index_patterns,
+ value: ['test-*'],
+ },
+ {
+ type: BulkActionEditType.set_index_patterns,
+ value: ['test-*'],
+ },
+ {
+ type: BulkActionEditType.delete_index_patterns,
+ value: ['test-*'],
+ },
+ {
+ type: BulkActionEditType.set_timeline,
+ value: { timeline_id: 'mock-id', timeline_title: 'mock-title' },
+ },
+ ];
+ cases.forEach(({ type, value }) => {
+ it(`should return error when trying to apply "${type}" edit action to prebuilt rule`, async () => {
+ await installPrePackagedRules(supertest, log);
+ const prebuiltRule = await fetchPrebuiltRule();
+
+ const { body } = await postBulkAction()
+ .send({
+ ids: [prebuiltRule.id],
+ action: BulkAction.edit,
+ [BulkAction.edit]: [
+ {
+ type,
+ value,
+ },
+ ],
+ })
+ .expect(500);
+
+ expect(body.attributes.summary).to.eql({ failed: 1, succeeded: 0, total: 1 });
+ expect(body.attributes.errors[0]).to.eql({
+ message: "Elastic rule can't be edited",
+ status_code: 500,
+ rules: [
+ {
+ id: prebuiltRule.id,
+ name: prebuiltRule.name,
+ },
+ ],
+ });
+ });
+ });
+ });
+
+ describe('rule actions', () => {
+ const webHookActionMock = {
+ group: 'default',
+ params: {
+ body: '{}',
+ },
+ };
+
+ describe('set_rule_actions', () => {
+ it('should set action correctly', async () => {
+ const ruleId = 'ruleId';
+ const createdRule = await createRule(supertest, log, getSimpleRule(ruleId));
+
+ // create a new action
+ const hookAction = await createWebHookAction();
+
+ const { body } = await postBulkAction()
+ .send({
+ ids: [createdRule.id],
+ action: BulkAction.edit,
+ [BulkAction.edit]: [
+ {
+ type: BulkActionEditType.set_rule_actions,
+ value: {
+ throttle: '1h',
+ actions: [
+ {
+ ...webHookActionMock,
+ id: hookAction.id,
+ },
+ ],
+ },
+ },
+ ],
+ })
+ .expect(200);
+
+ // Check that the updated rule is returned with the response
+ expect(body.attributes.results.updated[0].actions).to.eql([
+ {
+ ...webHookActionMock,
+ id: hookAction.id,
+ action_type_id: '.webhook',
+ },
+ ]);
+
+ // Check that the updates have been persisted
+ const { body: readRule } = await fetchRule(ruleId).expect(200);
+
+ expect(readRule.actions).to.eql([
+ {
+ ...webHookActionMock,
+ id: hookAction.id,
+ action_type_id: '.webhook',
+ },
+ ]);
+ });
+
+ it('should set actions to empty list, actions payload is empty list', async () => {
+ // create a new action
+ const hookAction = await createWebHookAction();
+
+ const defaultRuleAction = {
+ id: hookAction.id,
+ action_type_id: '.webhook',
+ group: 'default',
+ params: {
+ body: '{"test":"a default action"}',
+ },
+ };
+
+ const ruleId = 'ruleId';
+ const createdRule = await createRule(supertest, log, {
+ ...getSimpleRule(ruleId),
+ actions: [defaultRuleAction],
+ throttle: '1d',
+ });
+
+ const { body } = await postBulkAction()
+ .send({
+ ids: [createdRule.id],
+ action: BulkAction.edit,
+ [BulkAction.edit]: [
+ {
+ type: BulkActionEditType.set_rule_actions,
+ value: {
+ throttle: '1h',
+ actions: [],
+ },
+ },
+ ],
+ })
+ .expect(200);
+
+ // Check that the updated rule is returned with the response
+ expect(body.attributes.results.updated[0].actions).to.eql([]);
+
+ // Check that the updates have been persisted
+ const { body: readRule } = await fetchRule(ruleId).expect(200);
+
+ expect(readRule.actions).to.eql([]);
+ });
+ });
+
+ describe('add_rule_actions', () => {
+ it('should add action correctly to empty actions list', async () => {
+ const ruleId = 'ruleId';
+ const createdRule = await createRule(supertest, log, getSimpleRule(ruleId));
+
+ // create a new action
+ const hookAction = await createWebHookAction();
+
+ const { body } = await postBulkAction()
+ .send({
+ ids: [createdRule.id],
+ action: BulkAction.edit,
+ [BulkAction.edit]: [
+ {
+ type: BulkActionEditType.add_rule_actions,
+ value: {
+ throttle: '1h',
+ actions: [
+ {
+ ...webHookActionMock,
+ id: hookAction.id,
+ },
+ ],
+ },
+ },
+ ],
+ })
+ .expect(200);
+
+ // Check that the updated rule is returned with the response
+ expect(body.attributes.results.updated[0].actions).to.eql([
+ {
+ ...webHookActionMock,
+ id: hookAction.id,
+ action_type_id: '.webhook',
+ },
+ ]);
+
+ // Check that the updates have been persisted
+ const { body: readRule } = await fetchRule(ruleId).expect(200);
+
+ expect(readRule.actions).to.eql([
+ {
+ ...webHookActionMock,
+ id: hookAction.id,
+ action_type_id: '.webhook',
+ },
+ ]);
+ });
+
+ it('should add action correctly to non empty actions list', async () => {
+ // create a new action
+ const hookAction = await createWebHookAction();
+
+ const defaultRuleAction = {
+ id: hookAction.id,
+ action_type_id: '.webhook',
+ group: 'default',
+ params: {
+ body: '{"test":"a default action"}',
+ },
+ };
+
+ const ruleId = 'ruleId';
+ const createdRule = await createRule(supertest, log, {
+ ...getSimpleRule(ruleId),
+ actions: [defaultRuleAction],
+ throttle: '1d',
+ });
+
+ const { body } = await postBulkAction()
+ .send({
+ ids: [createdRule.id],
+ action: BulkAction.edit,
+ [BulkAction.edit]: [
+ {
+ type: BulkActionEditType.add_rule_actions,
+ value: {
+ throttle: '1h',
+ actions: [
+ {
+ ...webHookActionMock,
+ id: hookAction.id,
+ },
+ ],
+ },
+ },
+ ],
+ })
+ .expect(200);
+
+ // Check that the updated rule is returned with the response
+ expect(body.attributes.results.updated[0].actions).to.eql([
+ defaultRuleAction,
+ {
+ ...webHookActionMock,
+ id: hookAction.id,
+ action_type_id: '.webhook',
+ },
+ ]);
+
+ // Check that the updates have been persisted
+ const { body: readRule } = await fetchRule(ruleId).expect(200);
+
+ expect(readRule.actions).to.eql([
+ defaultRuleAction,
+ {
+ ...webHookActionMock,
+ id: hookAction.id,
+ action_type_id: '.webhook',
+ },
+ ]);
+ });
+
+ it('should not change actions of rule if empty list of actions added', async () => {
+ // create a new action
+ const hookAction = await createWebHookAction();
+
+ const defaultRuleAction = {
+ id: hookAction.id,
+ action_type_id: '.webhook',
+ group: 'default',
+ params: {
+ body: '{"test":"a default action"}',
+ },
+ };
+
+ const ruleId = 'ruleId';
+ const createdRule = await createRule(supertest, log, {
+ ...getSimpleRule(ruleId),
+ actions: [defaultRuleAction],
+ throttle: '1d',
+ });
+
+ const { body } = await postBulkAction()
+ .send({
+ ids: [createdRule.id],
+ action: BulkAction.edit,
+ [BulkAction.edit]: [
+ {
+ type: BulkActionEditType.add_rule_actions,
+ value: {
+ throttle: '1h',
+ actions: [],
+ },
+ },
+ ],
+ })
+ .expect(200);
+
+ // Check that the updated rule is returned with the response
+ expect(body.attributes.results.updated[0].actions).to.eql([defaultRuleAction]);
+
+ // Check that the updates have been persisted
+ const { body: readRule } = await fetchRule(ruleId).expect(200);
+
+ expect(readRule.actions).to.eql([defaultRuleAction]);
+ });
+
+ it('should change throttle if actions list in payload is empty', async () => {
+ // create a new action
+ const hookAction = await createWebHookAction();
+
+ const defaultRuleAction = {
+ id: hookAction.id,
+ action_type_id: '.webhook',
+ group: 'default',
+ params: {
+ body: '{"test":"a default action"}',
+ },
+ };
+
+ const ruleId = 'ruleId';
+ const createdRule = await createRule(supertest, log, {
+ ...getSimpleRule(ruleId),
+ actions: [defaultRuleAction],
+ throttle: '8h',
+ });
+
+ const { body } = await postBulkAction()
+ .send({
+ ids: [createdRule.id],
+ action: BulkAction.edit,
+ [BulkAction.edit]: [
+ {
+ type: BulkActionEditType.add_rule_actions,
+ value: {
+ throttle: '1h',
+ actions: [],
+ },
+ },
+ ],
+ })
+ .expect(200);
+
+ // Check that the updated rule is returned with the response
+ expect(body.attributes.results.updated[0].throttle).to.be('1h');
+
+ // Check that the updates have been persisted
+ const { body: readRule } = await fetchRule(ruleId).expect(200);
+
+ expect(readRule.throttle).to.eql('1h');
+ });
+ });
+
+ describe('prebuilt rules', () => {
+ const cases = [
+ {
+ type: BulkActionEditType.set_rule_actions,
+ },
+ {
+ type: BulkActionEditType.add_rule_actions,
+ },
+ ];
+ cases.forEach(({ type }) => {
+ it(`should apply "${type}" rule action to prebuilt rule`, async () => {
+ await installPrePackagedRules(supertest, log);
+ const prebuiltRule = await fetchPrebuiltRule();
+ const hookAction = await createWebHookAction();
+
+ const { body } = await postBulkAction()
+ .send({
+ ids: [prebuiltRule.id],
+ action: BulkAction.edit,
+ [BulkAction.edit]: [
+ {
+ type,
+ value: {
+ throttle: '1h',
+ actions: [
+ {
+ ...webHookActionMock,
+ id: hookAction.id,
+ },
+ ],
+ },
+ },
+ ],
+ })
+ .expect(200);
+
+ const editedRule = body.attributes.results.updated[0];
+ // Check that the updated rule is returned with the response
+ expect(editedRule.actions).to.eql([
+ {
+ ...webHookActionMock,
+ id: hookAction.id,
+ action_type_id: '.webhook',
+ },
+ ]);
+ // version of prebuilt rule should not change
+ expect(editedRule.version).to.be(prebuiltRule.version);
+
+ // Check that the updates have been persisted
+ const { body: readRule } = await fetchRule(prebuiltRule.rule_id).expect(200);
+
+ expect(readRule.actions).to.eql([
+ {
+ ...webHookActionMock,
+ id: hookAction.id,
+ action_type_id: '.webhook',
+ },
+ ]);
+ expect(prebuiltRule.version).to.be(readRule.version);
+ });
+ });
+
+ // if rule action is applied together with another edit action, that can't be applied to prebuilt rule (for example: tags action)
+ // bulk edit request should return error
+ it(`should return error if one of edit action is not eligible for prebuilt rule`, async () => {
+ await installPrePackagedRules(supertest, log);
+ const prebuiltRule = await fetchPrebuiltRule();
+ const hookAction = await createWebHookAction();
+
+ const { body } = await postBulkAction()
+ .send({
+ ids: [prebuiltRule.id],
+ action: BulkAction.edit,
+ [BulkAction.edit]: [
+ {
+ type: BulkActionEditType.set_rule_actions,
+ value: {
+ throttle: '1h',
+ actions: [
+ {
+ ...webHookActionMock,
+ id: hookAction.id,
+ },
+ ],
+ },
+ },
+ {
+ type: BulkActionEditType.set_tags,
+ value: ['tag-1'],
+ },
+ ],
+ })
+ .expect(500);
+
+ expect(body.attributes.summary).to.eql({ failed: 1, succeeded: 0, total: 1 });
+ expect(body.attributes.errors[0]).to.eql({
+ message: "Elastic rule can't be edited",
+ status_code: 500,
+ rules: [
+ {
+ id: prebuiltRule.id,
+ name: prebuiltRule.name,
+ },
+ ],
+ });
+
+ // Check that the updates were not made
+ const { body: readRule } = await fetchRule(prebuiltRule.rule_id).expect(200);
+
+ expect(readRule.actions).to.eql(prebuiltRule.actions);
+ expect(readRule.tags).to.eql(prebuiltRule.tags);
+ expect(readRule.version).to.be(prebuiltRule.version);
+ });
+ });
+
+ describe('throttle', () => {
+ const casesForEmptyActions = [
+ {
+ payloadThrottle: NOTIFICATION_THROTTLE_NO_ACTIONS,
+ },
+ {
+ payloadThrottle: NOTIFICATION_THROTTLE_RULE,
+ },
+ {
+ payloadThrottle: '1d',
+ },
+ ];
+ casesForEmptyActions.forEach(({ payloadThrottle }) => {
+ it(`throttle is set to NOTIFICATION_THROTTLE_NO_ACTIONS, if payload throttle="${payloadThrottle}" and actions list is empty`, async () => {
+ const ruleId = 'ruleId';
+ const createdRule = await createRule(supertest, log, {
+ ...getSimpleRule(ruleId),
+ throttle: '8h',
+ });
+
+ const { body } = await postBulkAction()
+ .send({
+ ids: [createdRule.id],
+ action: BulkAction.edit,
+ [BulkAction.edit]: [
+ {
+ type: BulkActionEditType.set_rule_actions,
+ value: {
+ throttle: payloadThrottle,
+ actions: [],
+ },
+ },
+ ],
+ })
+ .expect(200);
+
+ // Check that the updated rule is returned with the response
+ expect(body.attributes.results.updated[0].throttle).to.eql(
+ NOTIFICATION_THROTTLE_NO_ACTIONS
+ );
+
+ // Check that the updates have been persisted
+ const { body: rule } = await fetchRule(ruleId).expect(200);
+
+ expect(rule.throttle).to.eql(NOTIFICATION_THROTTLE_NO_ACTIONS);
+ });
+ });
+
+ const casesForNonEmptyActions = [
+ {
+ payloadThrottle: NOTIFICATION_THROTTLE_NO_ACTIONS,
+ expectedThrottle: NOTIFICATION_THROTTLE_NO_ACTIONS,
+ },
+ {
+ payloadThrottle: NOTIFICATION_THROTTLE_RULE,
+ expectedThrottle: NOTIFICATION_THROTTLE_RULE,
+ },
+ {
+ payloadThrottle: '1h',
+ expectedThrottle: '1h',
+ },
+ ];
+ casesForNonEmptyActions.forEach(({ payloadThrottle, expectedThrottle }) => {
+ it(`throttle is set correctly, if payload throttle="${payloadThrottle}" and actions non empty`, async () => {
+ // create a new action
+ const hookAction = await createWebHookAction();
+
+ const ruleId = 'ruleId';
+ const createdRule = await createRule(supertest, log, getSimpleRule(ruleId));
+
+ const { body } = await postBulkAction()
+ .send({
+ ids: [createdRule.id],
+ action: BulkAction.edit,
+ [BulkAction.edit]: [
+ {
+ type: BulkActionEditType.set_rule_actions,
+ value: {
+ throttle: payloadThrottle,
+ actions: [
+ {
+ id: hookAction.id,
+ group: 'default',
+ params: { body: '{}' },
+ },
+ ],
+ },
+ },
+ ],
+ })
+ .expect(200);
+
+ // Check that the updated rule is returned with the response
+ expect(body.attributes.results.updated[0].throttle).to.eql(expectedThrottle);
+
+ // Check that the updates have been persisted
+ const { body: rule } = await fetchRule(ruleId).expect(200);
+
+ expect(rule.throttle).to.eql(expectedThrottle);
+ });
+ });
+ });
+
+ describe('notifyWhen', () => {
+ const cases = [
+ {
+ payload: { throttle: NOTIFICATION_THROTTLE_NO_ACTIONS },
+ // keeps existing default value which is onActiveAlert
+ expected: { notifyWhen: 'onActiveAlert' },
+ },
+ {
+ payload: { throttle: '1d' },
+ expected: { notifyWhen: 'onThrottleInterval' },
+ },
+ {
+ payload: { throttle: NOTIFICATION_THROTTLE_RULE },
+ expected: { notifyWhen: 'onActiveAlert' },
+ },
+ ];
+ cases.forEach(({ payload, expected }) => {
+ it(`should set notifyWhen correctly, if payload throttle="${payload.throttle}"`, async () => {
+ const createdRule = await createRule(supertest, log, getSimpleRule('ruleId'));
+
+ await postBulkAction()
+ .send({
+ ids: [createdRule.id],
+ action: BulkAction.edit,
+ [BulkAction.edit]: [
+ {
+ type: BulkActionEditType.set_rule_actions,
+ value: {
+ throttle: payload.throttle,
+ actions: [],
+ },
+ },
+ ],
+ })
+ .expect(200);
+
+ // Check whether notifyWhen set correctly
+ const { body: rule } = await fetchRuleByAlertApi(createdRule.id).expect(200);
+
+ expect(rule.notify_when).to.eql(expected.notifyWhen);
+ });
+ });
+ });
+ });
});
describe('overwrite_data_views', () => {
diff --git a/x-pack/test/detection_engine_api_integration/security_and_spaces/group1/perform_bulk_action_dry_run.ts b/x-pack/test/detection_engine_api_integration/security_and_spaces/group1/perform_bulk_action_dry_run.ts
index 429b34f3f0a54..e9c3b3b68487d 100644
--- a/x-pack/test/detection_engine_api_integration/security_and_spaces/group1/perform_bulk_action_dry_run.ts
+++ b/x-pack/test/detection_engine_api_integration/security_and_spaces/group1/perform_bulk_action_dry_run.ts
@@ -13,7 +13,7 @@ import {
import {
BulkAction,
BulkActionEditType,
-} from '@kbn/security-solution-plugin/common/detection_engine/schemas/common/schemas';
+} from '@kbn/security-solution-plugin/common/detection_engine/schemas/request/perform_bulk_action_schema';
import { FtrProviderContext } from '../../common/ftr_provider_context';
import {
createRule,
diff --git a/x-pack/test/functional/apps/ml/data_frame_analytics/classification_creation_saved_search.ts b/x-pack/test/functional/apps/ml/data_frame_analytics/classification_creation_saved_search.ts
index 67550ae17a4b0..b47a80c3041e2 100644
--- a/x-pack/test/functional/apps/ml/data_frame_analytics/classification_creation_saved_search.ts
+++ b/x-pack/test/functional/apps/ml/data_frame_analytics/classification_creation_saved_search.ts
@@ -19,6 +19,13 @@ export default function ({ getService }: FtrProviderContext) {
await ml.testResources.createIndexPatternIfNeeded('ft_farequote_small', '@timestamp');
await ml.testResources.createSavedSearchFarequoteLuceneIfNeeded('ft_farequote_small');
await ml.testResources.createSavedSearchFarequoteKueryIfNeeded('ft_farequote_small');
+ // Need to use the saved searches with filters that match multiple airlines
+ await ml.testResources.createSavedSearchFarequoteFilterTwoAndLuceneIfNeeded(
+ 'ft_farequote_small'
+ );
+ await ml.testResources.createSavedSearchFarequoteFilterTwoAndKueryIfNeeded(
+ 'ft_farequote_small'
+ );
await ml.testResources.setKibanaTimeZoneToUTC();
await ml.securityUI.loginAsMlPowerUser();
@@ -134,6 +141,110 @@ export default function ({ getService }: FtrProviderContext) {
} as AnalyticsTableRowDetails,
},
},
+ {
+ suiteTitle: 'with filter and lucene query',
+ jobType: 'classification',
+ jobId: `fq_saved_search_4_${dateNow}`,
+ jobDescription: 'Classification job based on a saved search with filter and lucene query',
+ source: 'ft_farequote_filter_two_and_lucene',
+ get destinationIndex(): string {
+ return `user-${this.jobId}`;
+ },
+ runtimeFields: {
+ uppercase_airline: {
+ type: 'keyword',
+ script: 'emit(params._source.airline.toUpperCase())',
+ },
+ },
+ dependentVariable: 'airline',
+ trainingPercent: 20,
+ modelMemory: '20mb',
+ createIndexPattern: true,
+ expected: {
+ source: 'ft_farequote_small',
+ rocCurveColorState: [
+ // tick/grid/axis
+ { color: '#DDDDDD', percentage: 38 },
+ // line
+ { color: '#98A2B3', percentage: 7 },
+ ],
+ runtimeFieldsEditorContent: ['{', ' "uppercase_airline": {', ' "type": "keyword",'],
+ row: {
+ memoryStatus: 'ok',
+ type: 'classification',
+ status: 'stopped',
+ progress: '100',
+ },
+ rowDetails: {
+ jobDetails: [
+ {
+ section: 'state',
+ expectedEntries: {
+ id: `fq_saved_search_4_${dateNow}`,
+ state: 'stopped',
+ data_counts:
+ '{"training_docs_count":135,"test_docs_count":544,"skipped_docs_count":0}',
+ description:
+ 'Classification job based on a saved search with filter and lucene query',
+ },
+ },
+ { section: 'progress', expectedEntries: { Phase: '8/8' } },
+ ],
+ } as AnalyticsTableRowDetails,
+ },
+ },
+ {
+ suiteTitle: 'with filter and kuery query',
+ jobType: 'classification',
+ jobId: `fq_saved_search_5_${dateNow}`,
+ jobDescription: 'Classification job based on a saved search with filter and kuery query',
+ source: 'ft_farequote_filter_two_and_kuery',
+ get destinationIndex(): string {
+ return `user-${this.jobId}`;
+ },
+ runtimeFields: {
+ uppercase_airline: {
+ type: 'keyword',
+ script: 'emit(params._source.airline.toUpperCase())',
+ },
+ },
+ dependentVariable: 'airline',
+ trainingPercent: 20,
+ modelMemory: '20mb',
+ createIndexPattern: true,
+ expected: {
+ source: 'ft_farequote_small',
+ rocCurveColorState: [
+ // tick/grid/axis
+ { color: '#DDDDDD', percentage: 38 },
+ // line
+ { color: '#98A2B3', percentage: 7 },
+ ],
+ runtimeFieldsEditorContent: ['{', ' "uppercase_airline": {', ' "type": "keyword",'],
+ row: {
+ memoryStatus: 'ok',
+ type: 'classification',
+ status: 'stopped',
+ progress: '100',
+ },
+ rowDetails: {
+ jobDetails: [
+ {
+ section: 'state',
+ expectedEntries: {
+ id: `fq_saved_search_5_${dateNow}`,
+ state: 'stopped',
+ data_counts:
+ '{"training_docs_count":109,"test_docs_count":436,"skipped_docs_count":0}',
+ description:
+ 'Classification job based on a saved search with filter and kuery query',
+ },
+ },
+ { section: 'progress', expectedEntries: { Phase: '8/8' } },
+ ],
+ } as AnalyticsTableRowDetails,
+ },
+ },
];
for (const testData of testDataList) {
diff --git a/x-pack/test/functional/apps/ml/data_frame_analytics/outlier_detection_creation_saved_search.ts b/x-pack/test/functional/apps/ml/data_frame_analytics/outlier_detection_creation_saved_search.ts
index 1dc431c74a97d..cd6690202e203 100644
--- a/x-pack/test/functional/apps/ml/data_frame_analytics/outlier_detection_creation_saved_search.ts
+++ b/x-pack/test/functional/apps/ml/data_frame_analytics/outlier_detection_creation_saved_search.ts
@@ -19,6 +19,10 @@ export default function ({ getService }: FtrProviderContext) {
await ml.testResources.createIndexPatternIfNeeded('ft_farequote_small', '@timestamp');
await ml.testResources.createSavedSearchFarequoteLuceneIfNeeded('ft_farequote_small');
await ml.testResources.createSavedSearchFarequoteKueryIfNeeded('ft_farequote_small');
+ await ml.testResources.createSavedSearchFarequoteFilterAndLuceneIfNeeded(
+ 'ft_farequote_small'
+ );
+ await ml.testResources.createSavedSearchFarequoteFilterAndKueryIfNeeded('ft_farequote_small');
await ml.testResources.setKibanaTimeZoneToUTC();
await ml.securityUI.loginAsMlPowerUser();
@@ -56,22 +60,6 @@ export default function ({ getService }: FtrProviderContext) {
{ chartAvailable: true, id: 'responsetime', legend: '4.91 - 171.08' },
{ chartAvailable: true, id: 'airline', legend: '5 categories' },
],
- scatterplotMatrixColorsWizard: [
- // markers
- { color: '#52B398', percentage: 15 },
- // grey boilerplate
- { color: '#6A717D', percentage: 13 },
- ],
- scatterplotMatrixColorStatsResults: [
- // red markers
- { color: '#D98071', percentage: 1 },
- // tick/grid/axis, grey markers
- { color: '#6A717D', percentage: 12 },
- { color: '#D3DAE6', percentage: 8 },
- { color: '#98A1B3', percentage: 12 },
- // anti-aliasing
- { color: '#F5F7FA', percentage: 30 },
- ],
runtimeFieldsEditorContent: ['{', ' "uppercase_airline": {', ' "type": "keyword",'],
row: {
memoryStatus: 'ok',
@@ -120,22 +108,6 @@ export default function ({ getService }: FtrProviderContext) {
{ chartAvailable: true, id: 'responsetime', legend: '9.91 - 171.08' },
{ chartAvailable: true, id: 'airline', legend: '5 categories' },
],
- scatterplotMatrixColorsWizard: [
- // markers
- { color: '#52B398', percentage: 15 },
- // grey boilerplate
- { color: '#6A717D', percentage: 13 },
- ],
- scatterplotMatrixColorStatsResults: [
- // red markers
- { color: '#D98071', percentage: 1 },
- // tick/grid/axis, grey markers
- { color: '#6A717D', percentage: 12 },
- { color: '#D3DAE6', percentage: 8 },
- { color: '#98A1B3', percentage: 12 },
- // anti-aliasing
- { color: '#F5F7FA', percentage: 30 },
- ],
runtimeFieldsEditorContent: ['{', ' "uppercase_airline": {', ' "type": "keyword",'],
row: {
memoryStatus: 'ok',
@@ -160,6 +132,105 @@ export default function ({ getService }: FtrProviderContext) {
} as AnalyticsTableRowDetails,
},
},
+ {
+ suiteTitle: 'with filter and kuery query',
+ jobType: 'outlier_detection',
+ jobId: `fq_saved_search_4_${dateNow}`,
+ jobDescription: 'Outlier detection job based on a saved search with filter and kuery query',
+ source: 'ft_farequote_filter_and_kuery',
+ get destinationIndex(): string {
+ return `user-${this.jobId}`;
+ },
+ runtimeFields: {
+ uppercase_airline: {
+ type: 'keyword',
+ script: 'emit(params._source.airline.toUpperCase())',
+ },
+ },
+ modelMemory: '65mb',
+ createIndexPattern: true,
+ expected: {
+ source: 'ft_farequote_small',
+ histogramCharts: [
+ { chartAvailable: true, id: 'uppercase_airline', legend: '1 category' },
+ { chartAvailable: true, id: 'responsetime', legend: '57.2 - 96.77' },
+ { chartAvailable: true, id: 'airline', legend: '1 category' },
+ ],
+ runtimeFieldsEditorContent: ['{', ' "uppercase_airline": {', ' "type": "keyword",'],
+ row: {
+ memoryStatus: 'ok',
+ type: 'outlier_detection',
+ status: 'stopped',
+ progress: '100',
+ },
+ rowDetails: {
+ jobDetails: [
+ {
+ section: 'state',
+ expectedEntries: {
+ id: `fq_saved_search_4_${dateNow}`,
+ state: 'stopped',
+ data_counts:
+ '{"training_docs_count":290,"test_docs_count":0,"skipped_docs_count":0}',
+ description:
+ 'Outlier detection job based on a saved search with filter and kuery query',
+ },
+ },
+ { section: 'progress', expectedEntries: { Phase: '4/4' } },
+ ],
+ } as AnalyticsTableRowDetails,
+ },
+ },
+ {
+ suiteTitle: 'with filter and lucene query',
+ jobType: 'outlier_detection',
+ jobId: `fq_saved_search_5_${dateNow}`,
+ jobDescription:
+ 'Outlier detection job based on a saved search with filter and lucene query',
+ source: 'ft_farequote_filter_and_lucene',
+ get destinationIndex(): string {
+ return `user-${this.jobId}`;
+ },
+ runtimeFields: {
+ uppercase_airline: {
+ type: 'keyword',
+ script: 'emit(params._source.airline.toUpperCase())',
+ },
+ },
+ modelMemory: '65mb',
+ createIndexPattern: true,
+ expected: {
+ source: 'ft_farequote_small',
+ histogramCharts: [
+ { chartAvailable: true, id: 'uppercase_airline', legend: '1 category' },
+ { chartAvailable: true, id: 'responsetime', legend: '57.2 - 96.77' },
+ { chartAvailable: true, id: 'airline', legend: '1 category' },
+ ],
+ runtimeFieldsEditorContent: ['{', ' "uppercase_airline": {', ' "type": "keyword",'],
+ row: {
+ memoryStatus: 'ok',
+ type: 'outlier_detection',
+ status: 'stopped',
+ progress: '100',
+ },
+ rowDetails: {
+ jobDetails: [
+ {
+ section: 'state',
+ expectedEntries: {
+ id: `fq_saved_search_5_${dateNow}`,
+ state: 'stopped',
+ data_counts:
+ '{"training_docs_count":290,"test_docs_count":0,"skipped_docs_count":0}',
+ description:
+ 'Outlier detection job based on a saved search with filter and lucene query',
+ },
+ },
+ { section: 'progress', expectedEntries: { Phase: '4/4' } },
+ ],
+ } as AnalyticsTableRowDetails,
+ },
+ },
];
for (const testData of testDataList) {
diff --git a/x-pack/test/functional/apps/ml/data_frame_analytics/regression_creation_saved_search.ts b/x-pack/test/functional/apps/ml/data_frame_analytics/regression_creation_saved_search.ts
index e22c4908486d1..171ab6ee8c51e 100644
--- a/x-pack/test/functional/apps/ml/data_frame_analytics/regression_creation_saved_search.ts
+++ b/x-pack/test/functional/apps/ml/data_frame_analytics/regression_creation_saved_search.ts
@@ -19,6 +19,10 @@ export default function ({ getService }: FtrProviderContext) {
await ml.testResources.createIndexPatternIfNeeded('ft_farequote_small', '@timestamp');
await ml.testResources.createSavedSearchFarequoteLuceneIfNeeded('ft_farequote_small');
await ml.testResources.createSavedSearchFarequoteKueryIfNeeded('ft_farequote_small');
+ await ml.testResources.createSavedSearchFarequoteFilterAndLuceneIfNeeded(
+ 'ft_farequote_small'
+ );
+ await ml.testResources.createSavedSearchFarequoteFilterAndKueryIfNeeded('ft_farequote_small');
await ml.testResources.setKibanaTimeZoneToUTC();
await ml.securityUI.loginAsMlPowerUser();
@@ -122,6 +126,97 @@ export default function ({ getService }: FtrProviderContext) {
} as AnalyticsTableRowDetails,
},
},
+ {
+ suiteTitle: 'with filter and kuery query',
+ jobType: 'regression',
+ jobId: `fq_saved_search_4_${dateNow}`,
+ jobDescription: 'Regression job based on a saved search with filter and kuery query',
+ source: 'ft_farequote_filter_and_kuery',
+ get destinationIndex(): string {
+ return `user-${this.jobId}`;
+ },
+ runtimeFields: {
+ uppercase_airline: {
+ type: 'keyword',
+ script: 'emit(params._source.airline.toUpperCase())',
+ },
+ },
+ dependentVariable: 'responsetime',
+ trainingPercent: 20,
+ modelMemory: '20mb',
+ createIndexPattern: true,
+ expected: {
+ source: 'ft_farequote_small',
+ runtimeFieldsEditorContent: ['{', ' "uppercase_airline": {', ' "type": "keyword",'],
+ row: {
+ memoryStatus: 'ok',
+ type: 'regression',
+ status: 'stopped',
+ progress: '100',
+ },
+ rowDetails: {
+ jobDetails: [
+ {
+ section: 'state',
+ expectedEntries: {
+ id: `fq_saved_search_4_${dateNow}`,
+ state: 'stopped',
+ data_counts:
+ '{"training_docs_count":58,"test_docs_count":232,"skipped_docs_count":0}',
+ description: 'Regression job based on a saved search with filter and kuery query',
+ },
+ },
+ { section: 'progress', expectedEntries: { Phase: '8/8' } },
+ ],
+ } as AnalyticsTableRowDetails,
+ },
+ },
+ {
+ suiteTitle: 'with filter and lucene query',
+ jobType: 'regression',
+ jobId: `fq_saved_search_5_${dateNow}`,
+ jobDescription: 'Regression job based on a saved search with filter and lucene query',
+ source: 'ft_farequote_filter_and_lucene',
+ get destinationIndex(): string {
+ return `user-${this.jobId}`;
+ },
+ runtimeFields: {
+ uppercase_airline: {
+ type: 'keyword',
+ script: 'emit(params._source.airline.toUpperCase())',
+ },
+ },
+ dependentVariable: 'responsetime',
+ trainingPercent: 20,
+ modelMemory: '20mb',
+ createIndexPattern: true,
+ expected: {
+ source: 'ft_farequote_small',
+ runtimeFieldsEditorContent: ['{', ' "uppercase_airline": {', ' "type": "keyword",'],
+ row: {
+ memoryStatus: 'ok',
+ type: 'regression',
+ status: 'stopped',
+ progress: '100',
+ },
+ rowDetails: {
+ jobDetails: [
+ {
+ section: 'state',
+ expectedEntries: {
+ id: `fq_saved_search_5_${dateNow}`,
+ state: 'stopped',
+ data_counts:
+ '{"training_docs_count":58,"test_docs_count":232,"skipped_docs_count":0}',
+ description:
+ 'Regression job based on a saved search with filter and lucene query',
+ },
+ },
+ { section: 'progress', expectedEntries: { Phase: '8/8' } },
+ ],
+ } as AnalyticsTableRowDetails,
+ },
+ },
];
for (const testData of testDataList) {
diff --git a/x-pack/test/functional/services/ml/test_resources.ts b/x-pack/test/functional/services/ml/test_resources.ts
index 27faf74073184..4fccde6712e62 100644
--- a/x-pack/test/functional/services/ml/test_resources.ts
+++ b/x-pack/test/functional/services/ml/test_resources.ts
@@ -275,6 +275,24 @@ export function MachineLearningTestResourcesProvider(
);
},
+ async createSavedSearchFarequoteFilterTwoAndLuceneIfNeeded(
+ indexPatternTitle: string = 'ft_farequote'
+ ) {
+ await this.createSavedSearchIfNeeded(
+ savedSearches.farequoteFilterTwoAndLucene,
+ indexPatternTitle
+ );
+ },
+
+ async createSavedSearchFarequoteFilterTwoAndKueryIfNeeded(
+ indexPatternTitle: string = 'ft_farequote'
+ ) {
+ await this.createSavedSearchIfNeeded(
+ savedSearches.farequoteFilterTwoAndKuery,
+ indexPatternTitle
+ );
+ },
+
async deleteSavedObjectById(id: string, objectType: SavedObjectType, force: boolean = false) {
log.debug(`Deleting ${objectType} with id '${id}'...`);
diff --git a/x-pack/test/functional/services/ml/test_resources_data.ts b/x-pack/test/functional/services/ml/test_resources_data.ts
index aeacc51cecbc9..ac5c2241de81f 100644
--- a/x-pack/test/functional/services/ml/test_resources_data.ts
+++ b/x-pack/test/functional/services/ml/test_resources_data.ts
@@ -242,6 +242,132 @@ export const savedSearches = {
],
},
},
+ farequoteFilterTwoAndLucene: {
+ requestBody: {
+ attributes: {
+ title: 'ft_farequote_filter_two_and_lucene',
+ description: '',
+ hits: 0,
+ columns: ['_source'],
+ sort: ['@timestamp', 'desc'],
+ version: 1,
+ kibanaSavedObjectMeta: {
+ searchSourceJSON: {
+ highlightAll: true,
+ version: true,
+ query: {
+ query: 'responsetime:>50',
+ language: 'lucene',
+ },
+ filter: [
+ {
+ meta: {
+ index: 'INDEX_PATTERN_ID_PLACEHOLDER',
+ negate: false,
+ disabled: false,
+ alias: null,
+ type: 'phrases',
+ key: 'airline',
+ params: ['ASA', 'AAL'],
+ },
+ query: {
+ bool: {
+ should: [
+ {
+ match_phrase: {
+ airline: 'ASA',
+ },
+ },
+ {
+ match_phrase: {
+ airline: 'AAL',
+ },
+ },
+ ],
+ minimum_should_match: 1,
+ },
+ },
+ $state: {
+ store: 'appState',
+ },
+ },
+ ],
+ indexRefName: 'kibanaSavedObjectMeta.searchSourceJSON.index',
+ },
+ },
+ },
+ references: [
+ {
+ name: 'kibanaSavedObjectMeta.searchSourceJSON.index',
+ type: 'index-pattern',
+ id: 'INDEX_PATTERN_ID_PLACEHOLDER',
+ },
+ ],
+ },
+ },
+ farequoteFilterTwoAndKuery: {
+ requestBody: {
+ attributes: {
+ title: 'ft_farequote_filter_two_and_kuery',
+ description: '',
+ hits: 0,
+ columns: ['_source'],
+ sort: ['@timestamp', 'desc'],
+ version: 1,
+ kibanaSavedObjectMeta: {
+ searchSourceJSON: {
+ highlightAll: true,
+ version: true,
+ query: {
+ query: 'responsetime > 49',
+ language: 'kuery',
+ },
+ filter: [
+ {
+ meta: {
+ index: 'INDEX_PATTERN_ID_PLACEHOLDER',
+ negate: false,
+ disabled: false,
+ alias: null,
+ type: 'phrases',
+ key: 'airline',
+ params: ['ASA', 'FFT'],
+ },
+ query: {
+ bool: {
+ should: [
+ {
+ match_phrase: {
+ airline: 'ASA',
+ },
+ },
+ {
+ match_phrase: {
+ airline: 'FFT',
+ },
+ },
+ ],
+ minimum_should_match: 1,
+ },
+ },
+ $state: {
+ store: 'appState',
+ },
+ },
+ ],
+ indexRefName: 'kibanaSavedObjectMeta.searchSourceJSON.index',
+ },
+ },
+ },
+ references: [
+ {
+ name: 'kibanaSavedObjectMeta.searchSourceJSON.index',
+ type: 'index-pattern',
+ id: 'INDEX_PATTERN_ID_PLACEHOLDER',
+ },
+ ],
+ },
+ },
};
export const dashboards = {
diff --git a/x-pack/test/osquery_cypress/artifact_manager.ts b/x-pack/test/osquery_cypress/artifact_manager.ts
index 5bc80dc9aa710..bef18d0177220 100644
--- a/x-pack/test/osquery_cypress/artifact_manager.ts
+++ b/x-pack/test/osquery_cypress/artifact_manager.ts
@@ -5,11 +5,6 @@
* 2.0.
*/
-// import axios from 'axios';
-// import { last } from 'lodash';
-
export async function getLatestVersion(): Promise {
- return '8.4.0-SNAPSHOT';
- // const response: any = await axios('https://artifacts-api.elastic.co/v1/versions');
- // return last(response.data.versions as string[]) || '8.2.0-SNAPSHOT';
+ return '8.5.0-SNAPSHOT';
}
diff --git a/x-pack/test/performance/journeys/base.config.ts b/x-pack/test/performance/journeys/base.config.ts
index ef7170efa9c8f..ee0d298aec4a2 100644
--- a/x-pack/test/performance/journeys/base.config.ts
+++ b/x-pack/test/performance/journeys/base.config.ts
@@ -62,6 +62,8 @@ export default async function ({ readConfigFile, log }: FtrConfigProviderContext
...functionalConfig.get('kbnTestServer.serverArgs'),
`--telemetry.optIn=true`,
`--telemetry.labels=${JSON.stringify(telemetryLabels)}`,
+ '--csp.strict=false',
+ '--csp.warnLegacyBrowsers=false',
],
env: {
ELASTIC_APM_ACTIVE: process.env.TEST_PERFORMANCE_PHASE ? 'true' : 'false',
diff --git a/x-pack/test/performance/journeys/ecommerce_dashboard/ecommerce_dashboard.ts b/x-pack/test/performance/journeys/ecommerce_dashboard/ecommerce_dashboard.ts
index 67dabe30c90ff..5263c19902b93 100644
--- a/x-pack/test/performance/journeys/ecommerce_dashboard/ecommerce_dashboard.ts
+++ b/x-pack/test/performance/journeys/ecommerce_dashboard/ecommerce_dashboard.ts
@@ -7,6 +7,7 @@
import { Page } from 'playwright';
import { FtrProviderContext } from '../../ftr_provider_context';
import { StepCtx } from '../../services/performance';
+import { waitForVisualizations } from '../../utils';
export default function ({ getService }: FtrProviderContext) {
describe('ecommerce_dashboard', () => {
@@ -27,6 +28,8 @@ export default function ({ getService }: FtrProviderContext) {
{
name: 'Add Ecommerce Sample Data',
handler: async ({ page }: { page: Page }) => {
+ const showSampleDataButton = page.locator('[data-test-subj=showSampleDataButton]');
+ await showSampleDataButton.click();
const removeButton = page.locator('[data-test-subj=removeSampleDataSetecommerce]');
try {
await removeButton.click({ timeout: 1_000 });
@@ -45,16 +48,7 @@ export default function ({ getService }: FtrProviderContext) {
await page.click('[data-test-subj=launchSampleDataSetecommerce]');
await page.click('[data-test-subj=viewSampleDataSetecommerce-dashboard]');
- await page.waitForFunction(function renderCompleted() {
- const visualizations = Array.from(
- document.querySelectorAll('[data-rendering-count]')
- );
- const visualizationElementsLoaded = visualizations.length > 0;
- const visualizationAnimationsFinished = visualizations.every(
- (e) => e.getAttribute('data-render-complete') === 'true'
- );
- return visualizationElementsLoaded && visualizationAnimationsFinished;
- });
+ await waitForVisualizations(page, 13);
},
},
],
diff --git a/x-pack/test/performance/journeys/flight_dashboard/flight_dashboard.ts b/x-pack/test/performance/journeys/flight_dashboard/flight_dashboard.ts
index 344ae13511917..5967cd6ca80f3 100644
--- a/x-pack/test/performance/journeys/flight_dashboard/flight_dashboard.ts
+++ b/x-pack/test/performance/journeys/flight_dashboard/flight_dashboard.ts
@@ -6,6 +6,7 @@
*/
import { FtrProviderContext } from '../../ftr_provider_context';
import { StepCtx } from '../../services/performance';
+import { waitForVisualizations } from '../../utils';
export default function ({ getService }: FtrProviderContext) {
describe('flight_dashboard', () => {
@@ -26,6 +27,8 @@ export default function ({ getService }: FtrProviderContext) {
{
name: 'Add Flights Sample Data',
handler: async ({ page }) => {
+ const showSampleDataButton = page.locator('[data-test-subj=showSampleDataButton]');
+ await showSampleDataButton.click();
const removeButton = page.locator('[data-test-subj=removeSampleDataSetflights]');
try {
await removeButton.click({ timeout: 1_000 });
@@ -45,16 +48,7 @@ export default function ({ getService }: FtrProviderContext) {
await page.click('[data-test-subj=launchSampleDataSetflights]');
await page.click('[data-test-subj=viewSampleDataSetflights-dashboard]');
- await page.waitForFunction(function renderCompleted() {
- const visualizations = Array.from(
- document.querySelectorAll('[data-rendering-count]')
- );
- const visualizationElementsLoaded = visualizations.length > 0;
- const visualizationAnimationsFinished = visualizations.every(
- (e) => e.getAttribute('data-render-complete') === 'true'
- );
- return visualizationElementsLoaded && visualizationAnimationsFinished;
- });
+ await waitForVisualizations(page, 15);
},
},
{
@@ -69,12 +63,7 @@ export default function ({ getService }: FtrProviderContext) {
await page.click('[data-test-subj="embeddablePanelAction-editPanel"]');
- await page.waitForFunction(function renderCompleted() {
- const visualization = document.querySelector('[data-rendering-count]');
- return (
- visualization && visualization?.getAttribute('data-render-complete') === 'true'
- );
- });
+ await waitForVisualizations(page, 1);
},
},
],
diff --git a/x-pack/test/performance/journeys/promotion_tracking_dashboard/promotion_tracking_dashboard.ts b/x-pack/test/performance/journeys/promotion_tracking_dashboard/promotion_tracking_dashboard.ts
index fc38b718eb2a6..590bf38b401c0 100644
--- a/x-pack/test/performance/journeys/promotion_tracking_dashboard/promotion_tracking_dashboard.ts
+++ b/x-pack/test/performance/journeys/promotion_tracking_dashboard/promotion_tracking_dashboard.ts
@@ -6,6 +6,7 @@
*/
import { FtrProviderContext } from '../../ftr_provider_context';
import { StepCtx } from '../../services/performance';
+import { waitForVisualizations } from '../../utils';
export default function ({ getService }: FtrProviderContext) {
describe('promotion_tracking_dashboard', () => {
@@ -48,16 +49,7 @@ export default function ({ getService }: FtrProviderContext) {
{
name: 'Wait for visualization animations to finish',
handler: async ({ page }) => {
- await page.waitForFunction(function renderCompleted() {
- const visualizations = Array.from(
- document.querySelectorAll('[data-rendering-count]')
- );
- const visualizationElementsLoaded = visualizations.length > 0;
- const visualizationAnimationsFinished = visualizations.every(
- (e) => e.getAttribute('data-render-complete') === 'true'
- );
- return visualizationElementsLoaded && visualizationAnimationsFinished;
- });
+ await waitForVisualizations(page, 1);
},
},
],
diff --git a/x-pack/test/performance/journeys/web_logs_dashboard/web_logs_dashboard.ts b/x-pack/test/performance/journeys/web_logs_dashboard/web_logs_dashboard.ts
index 6cb7b05df14d4..d7df55cac159c 100644
--- a/x-pack/test/performance/journeys/web_logs_dashboard/web_logs_dashboard.ts
+++ b/x-pack/test/performance/journeys/web_logs_dashboard/web_logs_dashboard.ts
@@ -6,6 +6,7 @@
*/
import { FtrProviderContext } from '../../ftr_provider_context';
import { StepCtx } from '../../services/performance';
+import { waitForVisualizations } from '../../utils';
export default function ({ getService }: FtrProviderContext) {
describe('weblogs_dashboard', () => {
@@ -26,6 +27,8 @@ export default function ({ getService }: FtrProviderContext) {
{
name: 'Add Web Logs Sample Data',
handler: async ({ page }) => {
+ const showSampleDataButton = page.locator('[data-test-subj=showSampleDataButton]');
+ await showSampleDataButton.click();
const removeButton = page.locator('[data-test-subj=removeSampleDataSetlogs]');
try {
await removeButton.click({ timeout: 1_000 });
@@ -45,16 +48,7 @@ export default function ({ getService }: FtrProviderContext) {
await page.click('[data-test-subj=launchSampleDataSetlogs]');
await page.click('[data-test-subj=viewSampleDataSetlogs-dashboard]');
- await page.waitForFunction(function renderCompleted() {
- const visualizations = Array.from(
- document.querySelectorAll('[data-rendering-count]')
- );
- const visualizationElementsLoaded = visualizations.length > 0;
- const visualizationAnimationsFinished = visualizations.every(
- (e) => e.getAttribute('data-render-complete') === 'true'
- );
- return visualizationElementsLoaded && visualizationAnimationsFinished;
- });
+ await waitForVisualizations(page, 12);
},
},
],
diff --git a/x-pack/test/performance/services/performance.ts b/x-pack/test/performance/services/performance.ts
index 2afd9f3e78393..7f7156284d186 100644
--- a/x-pack/test/performance/services/performance.ts
+++ b/x-pack/test/performance/services/performance.ts
@@ -183,8 +183,7 @@ export class PerformanceTestingService extends FtrService {
) {
return this.withTransaction(`Journey ${journeyName}`, async () => {
const browser = await this.getBrowserInstance();
- const viewport = { width: 1600, height: 1200 };
- const context = await browser.newContext({ viewport });
+ const context = await browser.newContext({ bypassCSP: true });
if (!requireAuth) {
const cookie = await this.auth.login({ username: 'elastic', password: 'changeme' });
diff --git a/x-pack/test/performance/utils.ts b/x-pack/test/performance/utils.ts
index bb6f8e0aebe64..1e9e754088418 100644
--- a/x-pack/test/performance/utils.ts
+++ b/x-pack/test/performance/utils.ts
@@ -5,8 +5,21 @@
* 2.0.
*/
+import { Page } from 'playwright';
+
export function serializeApmGlobalLabels(obj: any) {
return Object.entries(obj)
.filter(([, v]) => !!v)
.reduce((acc, [k, v]) => (acc ? `${acc},${k}=${v}` : `${k}=${v}`), '');
}
+
+export function waitForVisualizations(page: Page, visCount: number) {
+ return page.waitForFunction(function renderCompleted(cnt) {
+ const visualizations = Array.from(document.querySelectorAll('[data-rendering-count]'));
+ const visualizationElementsLoaded = visualizations.length === cnt;
+ const visualizationAnimationsFinished = visualizations.every(
+ (e) => e.getAttribute('data-render-complete') === 'true'
+ );
+ return visualizationElementsLoaded && visualizationAnimationsFinished;
+ }, visCount);
+}
diff --git a/x-pack/test/screenshot_creation/apps/ml_docs/data_frame_analytics/classification.ts b/x-pack/test/screenshot_creation/apps/ml_docs/data_frame_analytics/classification.ts
index 5fcbd6f2cb998..63f40f46023b8 100644
--- a/x-pack/test/screenshot_creation/apps/ml_docs/data_frame_analytics/classification.ts
+++ b/x-pack/test/screenshot_creation/apps/ml_docs/data_frame_analytics/classification.ts
@@ -126,6 +126,7 @@ export default function ({ getService }: FtrProviderContext) {
await ml.dataFrameAnalyticsResults.expandClassificationEvaluationSection(false);
await ml.dataFrameAnalyticsResults.expandFeatureImportanceSection(false);
await ml.dataFrameAnalyticsResults.expandScatterplotMatrixSection(false);
+ await ml.dataFrameAnalyticsResults.enableResultsTablePreviewHistogramCharts(true);
await ml.dataFrameAnalyticsResults.scrollAnalysisIntoView();
await commonScreenshots.removeFocusFromElement();
await commonScreenshots.takeScreenshot(
@@ -156,7 +157,7 @@ export default function ({ getService }: FtrProviderContext) {
'confusion-matrix-binary-accuracy',
screenshotDirectories
);
- await ml.dataFrameAnalyticsResults.scrollRocCurveChartIntoView();
+ await ml.dataFrameAnalyticsResults.scrollClassificationEvaluationIntoView();
await commonScreenshots.takeScreenshot(
'flights-classification-roc-curve',
screenshotDirectories