diff --git a/.buildkite/pipelines/security_solution/base.yml b/.buildkite/pipelines/security_solution/security_solution_cypress.yml similarity index 79% rename from .buildkite/pipelines/security_solution/base.yml rename to .buildkite/pipelines/security_solution/security_solution_cypress.yml index 337c44ccdcc7e..247505ef1c85a 100644 --- a/.buildkite/pipelines/security_solution/base.yml +++ b/.buildkite/pipelines/security_solution/security_solution_cypress.yml @@ -1,5 +1,5 @@ steps: - - command: .buildkite/scripts/pipelines/security_solution_quality_gate/mki_security_solution_cypress.sh cypress:run:qa:serverless + - command: .buildkite/scripts/pipelines/security_solution_quality_gate/security_solution_cypress/mki_security_solution_cypress.sh cypress:run:qa:serverless label: 'Serverless MKI QA Security Cypress Tests' agents: queue: n2-4-spot @@ -11,7 +11,7 @@ steps: - exit_status: '*' limit: 1 - - command: .buildkite/scripts/pipelines/security_solution_quality_gate/mki_security_solution_cypress.sh cypress:run:qa:serverless:explore + - command: .buildkite/scripts/pipelines/security_solution_quality_gate/security_solution_cypress/mki_security_solution_cypress.sh cypress:run:qa:serverless:explore label: 'Serverless MKI QA Explore - Security Solution Cypress Tests' agents: queue: n2-4-spot @@ -23,7 +23,7 @@ steps: - exit_status: '*' limit: 1 - - command: .buildkite/scripts/pipelines/security_solution_quality_gate/mki_security_solution_cypress.sh cypress:run:qa:serverless:investigations + - command: .buildkite/scripts/pipelines/security_solution_quality_gate/security_solution_cypress/mki_security_solution_cypress.sh cypress:run:qa:serverless:investigations label: 'Serverless MKI QA Investigations - Security Solution Cypress Tests' agents: queue: n2-4-spot diff --git a/.buildkite/scripts/pipelines/security_solution_quality_gate/edr_workflows/pipeline.sh b/.buildkite/scripts/pipelines/security_solution_quality_gate/edr_workflows/pipeline.sh new file mode 100755 index 0000000000000..807ec48ab48ed --- /dev/null +++ b/.buildkite/scripts/pipelines/security_solution_quality_gate/edr_workflows/pipeline.sh @@ -0,0 +1,5 @@ +#!/bin/bash + +set -euo pipefail + +echo "Running the EDR-Workflows testing for Kibana" \ No newline at end of file diff --git a/.buildkite/scripts/pipelines/security_solution_quality_gate/mki_security_solution_cypress.sh b/.buildkite/scripts/pipelines/security_solution_quality_gate/security_solution_cypress/mki_security_solution_cypress.sh similarity index 100% rename from .buildkite/scripts/pipelines/security_solution_quality_gate/mki_security_solution_cypress.sh rename to .buildkite/scripts/pipelines/security_solution_quality_gate/security_solution_cypress/mki_security_solution_cypress.sh diff --git a/.buildkite/scripts/pipelines/security_solution_quality_gate/pipeline.sh b/.buildkite/scripts/pipelines/security_solution_quality_gate/security_solution_cypress/pipeline.sh similarity index 100% rename from .buildkite/scripts/pipelines/security_solution_quality_gate/pipeline.sh rename to .buildkite/scripts/pipelines/security_solution_quality_gate/security_solution_cypress/pipeline.sh diff --git a/.buildkite/scripts/pipelines/security_solution_quality_gate/pipeline.ts b/.buildkite/scripts/pipelines/security_solution_quality_gate/security_solution_cypress/pipeline.ts similarity index 90% rename from .buildkite/scripts/pipelines/security_solution_quality_gate/pipeline.ts rename to .buildkite/scripts/pipelines/security_solution_quality_gate/security_solution_cypress/pipeline.ts index 4084696d5c21c..fb9ec67fba888 100644 --- a/.buildkite/scripts/pipelines/security_solution_quality_gate/pipeline.ts +++ b/.buildkite/scripts/pipelines/security_solution_quality_gate/security_solution_cypress/pipeline.ts @@ -28,7 +28,9 @@ const uploadPipeline = (pipelineContent: string | object) => { try { const pipeline = []; - pipeline.push(getPipeline('.buildkite/pipelines/security_solution/base.yml', false)); + pipeline.push( + getPipeline('.buildkite/pipelines/security_solution/security_solution_cypress.yml', false) + ); // remove duplicated steps uploadPipeline([...new Set(pipeline)].join('\n')); } catch (ex) { diff --git a/.github/CODEOWNERS b/.github/CODEOWNERS index 1dc3be1a66d6d..94f4285976c2a 100644 --- a/.github/CODEOWNERS +++ b/.github/CODEOWNERS @@ -36,14 +36,14 @@ packages/analytics/shippers/elastic_v3/server @elastic/kibana-core packages/analytics/shippers/fullstory @elastic/kibana-core packages/analytics/shippers/gainsight @elastic/kibana-core packages/kbn-apm-config-loader @elastic/kibana-core @vigneshshanmugam -x-pack/plugins/apm_data_access @elastic/apm-ui -x-pack/plugins/apm @elastic/apm-ui -packages/kbn-apm-synthtrace @elastic/apm-ui -packages/kbn-apm-synthtrace-client @elastic/apm-ui -packages/kbn-apm-utils @elastic/apm-ui +x-pack/plugins/apm_data_access @elastic/obs-knowledge-team @elastic/obs-ux-infra_services-team +x-pack/plugins/apm @elastic/obs-ux-infra_services-team +packages/kbn-apm-synthtrace @elastic/obs-ux-infra_services-team +packages/kbn-apm-synthtrace-client @elastic/obs-ux-infra_services-team +packages/kbn-apm-utils @elastic/obs-ux-infra_services-team test/plugin_functional/plugins/app_link_test @elastic/kibana-core x-pack/test/usage_collection/plugins/application_usage_test @elastic/kibana-core -x-pack/plugins/asset_manager @elastic/infra-monitoring-ui +x-pack/plugins/asset_manager @elastic/obs-knowledge-team x-pack/test/security_api_integration/plugins/audit_log @elastic/kibana-security packages/kbn-axe-config @elastic/kibana-qa packages/kbn-babel-preset @elastic/kibana-operations @@ -300,7 +300,7 @@ x-pack/plugins/cross_cluster_replication @elastic/platform-deployment-management packages/kbn-crypto @elastic/kibana-security packages/kbn-crypto-browser @elastic/kibana-core x-pack/plugins/custom_branding @elastic/appex-sharedux -packages/kbn-custom-integrations @elastic/infra-monitoring-ui +packages/kbn-custom-integrations @elastic/obs-ux-logs-team src/plugins/custom_integrations @elastic/fleet packages/kbn-cypress-config @elastic/kibana-operations x-pack/plugins/dashboard_enhanced @elastic/kibana-presentation @@ -319,7 +319,7 @@ packages/deeplinks/analytics @elastic/kibana-data-discovery @elastic/kibana-pres packages/deeplinks/devtools @elastic/platform-deployment-management packages/deeplinks/management @elastic/platform-deployment-management packages/deeplinks/ml @elastic/ml-ui -packages/deeplinks/observability @elastic/apm-ui +packages/deeplinks/observability @elastic/obs-ux-logs-team packages/deeplinks/search @elastic/enterprise-search-frontend packages/default-nav/analytics @elastic/kibana-data-discovery @elastic/kibana-presentation @elastic/kibana-visualizations packages/default-nav/devtools @elastic/platform-deployment-management @@ -357,14 +357,14 @@ packages/kbn-es @elastic/kibana-operations packages/kbn-es-archiver @elastic/kibana-operations @elastic/appex-qa packages/kbn-es-errors @elastic/kibana-core packages/kbn-es-query @elastic/kibana-data-discovery -packages/kbn-es-types @elastic/kibana-core @elastic/apm-ui +packages/kbn-es-types @elastic/kibana-core @elastic/obs-knowledge-team src/plugins/es_ui_shared @elastic/platform-deployment-management packages/kbn-eslint-config @elastic/kibana-operations packages/kbn-eslint-plugin-disable @elastic/kibana-operations packages/kbn-eslint-plugin-eslint @elastic/kibana-operations -packages/kbn-eslint-plugin-i18n @elastic/actionable-observability +packages/kbn-eslint-plugin-i18n @elastic/obs-knowledge-team packages/kbn-eslint-plugin-imports @elastic/kibana-operations -packages/kbn-eslint-plugin-telemetry @elastic/actionable-observability +packages/kbn-eslint-plugin-telemetry @elastic/obs-knowledge-team x-pack/test/encrypted_saved_objects_api_integration/plugins/api_consumer_plugin @elastic/kibana-security packages/kbn-event-annotation-common @elastic/kibana-visualizations packages/kbn-event-annotation-components @elastic/kibana-visualizations @@ -374,8 +374,8 @@ x-pack/test/plugin_api_integration/plugins/event_log @elastic/response-ops x-pack/plugins/event_log @elastic/response-ops packages/kbn-expandable-flyout @elastic/security-threat-hunting-investigations packages/kbn-expect @elastic/kibana-operations @elastic/appex-qa -x-pack/examples/exploratory_view_example @elastic/uptime -x-pack/plugins/exploratory_view @elastic/uptime +x-pack/examples/exploratory_view_example @elastic/obs-ux-infra_services-team +x-pack/plugins/exploratory_view @elastic/obs-ux-infra_services-team src/plugins/expression_error @elastic/kibana-presentation src/plugins/chart_expressions/expression_gauge @elastic/kibana-visualizations src/plugins/chart_expressions/expression_heatmap @elastic/kibana-visualizations @@ -444,7 +444,7 @@ packages/kbn-import-resolver @elastic/kibana-operations x-pack/plugins/index_lifecycle_management @elastic/platform-deployment-management x-pack/plugins/index_management @elastic/platform-deployment-management test/plugin_functional/plugins/index_patterns @elastic/kibana-data-discovery -x-pack/packages/kbn-infra-forge @elastic/actionable-observability +x-pack/packages/kbn-infra-forge @elastic/obs-ux-management-team x-pack/plugins/infra @elastic/infra-monitoring-ui x-pack/plugins/ingest_pipelines @elastic/platform-deployment-management src/plugins/input_control_vis @elastic/kibana-presentation @@ -452,7 +452,7 @@ src/plugins/inspector @elastic/kibana-presentation src/plugins/interactive_setup @elastic/kibana-security test/interactive_setup_api_integration/plugins/test_endpoints @elastic/kibana-security packages/kbn-interpreter @elastic/kibana-visualizations -packages/kbn-io-ts-utils @elastic/apm-ui +packages/kbn-io-ts-utils @elastic/obs-knowledge-team packages/kbn-jest-serializers @elastic/kibana-operations packages/kbn-journeys @elastic/kibana-operations @elastic/appex-qa packages/kbn-json-ast @elastic/kibana-operations @@ -469,7 +469,7 @@ src/plugins/kibana_usage_collection @elastic/kibana-core src/plugins/kibana_utils @elastic/appex-sharedux x-pack/plugins/kubernetes_security @elastic/kibana-cloud-security-posture packages/kbn-language-documentation-popover @elastic/kibana-visualizations -packages/kbn-lens-embeddable-utils @elastic/infra-monitoring-ui +packages/kbn-lens-embeddable-utils @elastic/obs-ux-infra_services-team x-pack/plugins/lens @elastic/kibana-visualizations x-pack/plugins/license_api_guard @elastic/platform-deployment-management x-pack/plugins/license_management @elastic/platform-deployment-management @@ -480,10 +480,10 @@ packages/kbn-lint-ts-projects-cli @elastic/kibana-operations x-pack/plugins/lists @elastic/security-detection-engine examples/locator_examples @elastic/appex-sharedux examples/locator_explorer @elastic/appex-sharedux -x-pack/plugins/log_explorer @elastic/infra-monitoring-ui +x-pack/plugins/log_explorer @elastic/obs-ux-logs-team packages/kbn-logging @elastic/kibana-core packages/kbn-logging-mocks @elastic/kibana-core -x-pack/plugins/logs_shared @elastic/infra-monitoring-ui +x-pack/plugins/logs_shared @elastic/obs-ux-logs-team x-pack/plugins/logstash @elastic/logstash packages/kbn-managed-vscode-config @elastic/kibana-operations packages/kbn-managed-vscode-config-cli @elastic/kibana-operations @@ -506,7 +506,7 @@ x-pack/examples/third_party_maps_source_example @elastic/kibana-gis src/plugins/maps_ems @elastic/kibana-gis x-pack/plugins/maps @elastic/kibana-gis x-pack/packages/maps/vector_tile_utils @elastic/kibana-gis -x-pack/plugins/metrics_data_access @elastic/infra-monitoring-ui +x-pack/plugins/metrics_data_access @elastic/obs-knowledge-team x-pack/packages/ml/agg_utils @elastic/ml-ui x-pack/packages/ml/anomaly_utils @elastic/ml-ui x-pack/packages/ml/category_validator @elastic/ml-ui @@ -533,24 +533,24 @@ x-pack/packages/ml/string_hash @elastic/ml-ui x-pack/packages/ml/trained_models_utils @elastic/ml-ui x-pack/packages/ml/url_state @elastic/ml-ui packages/kbn-monaco @elastic/appex-sharedux -x-pack/plugins/monitoring_collection @elastic/infra-monitoring-ui -x-pack/plugins/monitoring @elastic/infra-monitoring-ui +x-pack/plugins/monitoring_collection @elastic/obs-ux-infra_services-team +x-pack/plugins/monitoring @elastic/obs-ux-infra_services-team src/plugins/navigation @elastic/appex-sharedux src/plugins/newsfeed @elastic/kibana-core test/common/plugins/newsfeed @elastic/kibana-core src/plugins/no_data_page @elastic/appex-sharedux x-pack/plugins/notifications @elastic/appex-sharedux packages/kbn-object-versioning @elastic/appex-sharedux -x-pack/plugins/observability_ai_assistant @elastic/obs-ai-assistant +x-pack/plugins/observability_ai_assistant @elastic/obs-knowledge-team x-pack/packages/observability/alert_details @elastic/actionable-observability x-pack/packages/observability/alerting_test_data @elastic/actionable-observability x-pack/test/cases_api_integration/common/plugins/observability @elastic/response-ops -x-pack/plugins/observability_log_explorer @elastic/infra-monitoring-ui -x-pack/plugins/observability_onboarding @elastic/apm-ui -x-pack/plugins/observability @elastic/actionable-observability +x-pack/plugins/observability_log_explorer @elastic/obs-ux-logs-team +x-pack/plugins/observability_onboarding @elastic/obs-ux-logs-team +x-pack/plugins/observability @elastic/obs-ux-management-team x-pack/plugins/observability_shared @elastic/observability-ui x-pack/test/security_api_integration/plugins/oidc_provider @elastic/kibana-security -test/common/plugins/otel_metrics @elastic/infra-monitoring-ui +test/common/plugins/otel_metrics @elastic/obs-ux-infra_services-team packages/kbn-openapi-generator @elastic/security-detection-rule-management packages/kbn-optimizer @elastic/kibana-operations packages/kbn-optimizer-webpack-helpers @elastic/kibana-operations @@ -567,9 +567,9 @@ packages/kbn-plugin-helpers @elastic/kibana-operations examples/portable_dashboards_example @elastic/kibana-presentation examples/preboot_example @elastic/kibana-security @elastic/kibana-core src/plugins/presentation_util @elastic/kibana-presentation -x-pack/plugins/profiling_data_access @elastic/profiling-ui -x-pack/plugins/profiling @elastic/profiling-ui -packages/kbn-profiling-utils @elastic/profiling-ui +x-pack/plugins/profiling_data_access @elastic/obs-ux-infra_services-team +x-pack/plugins/profiling @elastic/obs-ux-infra_services-team +packages/kbn-profiling-utils @elastic/obs-ux-infra_services-team x-pack/packages/kbn-random-sampling @elastic/kibana-visualizations packages/kbn-react-field @elastic/kibana-data-discovery packages/react/kibana_context/common @elastic/appex-sharedux @@ -598,8 +598,8 @@ packages/kbn-rison @elastic/kibana-operations x-pack/plugins/rollup @elastic/platform-deployment-management examples/routing_example @elastic/kibana-core packages/kbn-rrule @elastic/response-ops -packages/kbn-rule-data-utils @elastic/security-detections-response @elastic/actionable-observability @elastic/response-ops -x-pack/plugins/rule_registry @elastic/response-ops @elastic/actionable-observability +packages/kbn-rule-data-utils @elastic/security-detections-response @elastic/response-ops @elastic/obs-ux-management-team +x-pack/plugins/rule_registry @elastic/response-ops @elastic/obs-ux-management-team x-pack/plugins/runtime_fields @elastic/platform-deployment-management packages/kbn-safer-lodash-set @elastic/kibana-security x-pack/test/security_api_integration/plugins/saml_provider @elastic/kibana-security @@ -656,11 +656,11 @@ packages/kbn-securitysolution-rules @elastic/security-detection-engine packages/kbn-securitysolution-t-grid @elastic/security-detection-engine packages/kbn-securitysolution-utils @elastic/security-detection-engine packages/kbn-server-http-tools @elastic/kibana-core -packages/kbn-server-route-repository @elastic/apm-ui +packages/kbn-server-route-repository @elastic/obs-knowledge-team @elastic/obs-ux-management-team x-pack/plugins/serverless @elastic/appex-sharedux packages/serverless/settings/common @elastic/appex-sharedux @elastic/platform-deployment-management -x-pack/plugins/serverless_observability @elastic/appex-sharedux @elastic/apm-ui -packages/serverless/settings/observability_project @elastic/appex-sharedux @elastic/apm-ui @elastic/platform-deployment-management +x-pack/plugins/serverless_observability @elastic/appex-sharedux @elastic/obs-ux-management-team +packages/serverless/settings/observability_project @elastic/appex-sharedux @elastic/platform-deployment-management @elastic/obs-ux-management-team packages/serverless/project_switcher @elastic/appex-sharedux x-pack/plugins/serverless_search @elastic/enterprise-search-frontend packages/serverless/settings/search_project @elastic/enterprise-search-frontend @elastic/platform-deployment-management @@ -672,7 +672,7 @@ x-pack/plugins/session_view @elastic/kibana-cloud-security-posture packages/kbn-set-map @elastic/kibana-operations examples/share_examples @elastic/appex-sharedux src/plugins/share @elastic/appex-sharedux -packages/kbn-shared-svg @elastic/apm-ui +packages/kbn-shared-svg @elastic/obs-ux-infra_services-team packages/shared-ux/avatar/solution @elastic/appex-sharedux packages/shared-ux/button/exit_full_screen @elastic/appex-sharedux packages/shared-ux/button_toolbar @elastic/appex-sharedux @@ -721,7 +721,7 @@ packages/shared-ux/router/types @elastic/appex-sharedux packages/shared-ux/storybook/config @elastic/appex-sharedux packages/shared-ux/storybook/mock @elastic/appex-sharedux packages/kbn-shared-ux-utility @elastic/appex-sharedux -x-pack/packages/kbn-slo-schema @elastic/actionable-observability +x-pack/packages/kbn-slo-schema @elastic/obs-ux-management-team x-pack/plugins/snapshot_restore @elastic/platform-deployment-management packages/kbn-some-dev-log @elastic/kibana-operations packages/kbn-sort-package-json @elastic/kibana-operations @@ -738,7 +738,7 @@ packages/kbn-std @elastic/kibana-core packages/kbn-stdio-dev-helpers @elastic/kibana-operations packages/kbn-storybook @elastic/kibana-operations packages/kbn-subscription-tracking @elastic/security-threat-hunting-investigations -x-pack/plugins/synthetics @elastic/uptime +x-pack/plugins/synthetics @elastic/obs-ux-infra_services-team x-pack/test/alerting_api_integration/common/plugins/task_manager_fixture @elastic/response-ops x-pack/test/plugin_api_perf/plugins/task_manager_performance @elastic/response-ops x-pack/plugins/task_manager @elastic/response-ops @@ -768,7 +768,7 @@ x-pack/examples/triggers_actions_ui_example @elastic/response-ops x-pack/plugins/triggers_actions_ui @elastic/response-ops packages/kbn-ts-projects @elastic/kibana-operations packages/kbn-ts-type-check-cli @elastic/kibana-operations -packages/kbn-typed-react-router-config @elastic/apm-ui +packages/kbn-typed-react-router-config @elastic/obs-knowledge-team @elastic/obs-ux-management-team packages/kbn-ui-actions-browser @elastic/appex-sharedux x-pack/examples/ui_actions_enhanced_examples @elastic/appex-sharedux src/plugins/ui_actions_enhanced @elastic/appex-sharedux @@ -788,20 +788,20 @@ examples/unified_field_list_examples @elastic/kibana-data-discovery src/plugins/unified_histogram @elastic/kibana-data-discovery src/plugins/unified_search @elastic/kibana-visualizations x-pack/plugins/upgrade_assistant @elastic/platform-deployment-management -x-pack/plugins/uptime @elastic/uptime +x-pack/plugins/uptime @elastic/obs-ux-infra_services-team x-pack/plugins/drilldowns/url_drilldown @elastic/appex-sharedux src/plugins/url_forwarding @elastic/kibana-visualizations packages/kbn-url-state @elastic/security-threat-hunting-investigations src/plugins/usage_collection @elastic/kibana-core test/plugin_functional/plugins/usage_collection @elastic/kibana-core -packages/kbn-use-tracked-promise @elastic/infra-monitoring-ui +packages/kbn-use-tracked-promise @elastic/obs-ux-logs-team packages/kbn-user-profile-components @elastic/kibana-security examples/user_profile_examples @elastic/kibana-security x-pack/test/security_api_integration/plugins/user_profiles_consumer @elastic/kibana-security packages/kbn-utility-types @elastic/kibana-core packages/kbn-utility-types-jest @elastic/kibana-operations packages/kbn-utils @elastic/kibana-operations -x-pack/plugins/ux @elastic/uptime +x-pack/plugins/ux @elastic/obs-ux-infra_services-team examples/v8_profiler_examples @elastic/response-ops packages/kbn-validate-next-docs-cli @elastic/kibana-operations src/plugins/vis_default_editor @elastic/kibana-visualizations @@ -822,7 +822,7 @@ src/plugins/visualizations @elastic/kibana-visualizations x-pack/plugins/watcher @elastic/platform-deployment-management packages/kbn-web-worker-stub @elastic/kibana-operations packages/kbn-whereis-pkg-cli @elastic/kibana-operations -packages/kbn-xstate-utils @elastic/infra-monitoring-ui +packages/kbn-xstate-utils @elastic/obs-ux-logs-team packages/kbn-yarn-lock-validator @elastic/kibana-operations packages/kbn-zod-helpers @elastic/security-detection-rule-management #### @@ -927,24 +927,79 @@ packages/kbn-monaco/src/esql @elastic/kibana-visualizations ### Observability Plugins # Actionable observability -x-pack/packages/observability/alert_details @elastic/actionable-observability -x-pack/test/observability_functional @elastic/actionable-observability -x-pack/plugins/infra/public/alerting @elastic/actionable-observability -x-pack/plugins/infra/server/lib/alerting @elastic/actionable-observability +x-pack/packages/observability/alert_details @elastic/obs-ux-management-team +x-pack/test/observability_functional @elastic/obs-ux-management-team +x-pack/plugins/infra/public/alerting @elastic/obs-ux-management-team +x-pack/plugins/infra/server/lib/alerting @elastic/obs-ux-management-team # Observability robots /.github/workflows/deploy-my-kibana.yml @elastic/observablt-robots /.github/workflows/oblt-github-commands @elastic/observablt-robots # Infra Monitoring -/x-pack/test/functional/apps/infra @elastic/infra-monitoring-ui -/x-pack/test/api_integration/apis/infra @elastic/infra-monitoring-ui +/x-pack/plugins/infra @elastic/obs-ux-infra_services-team @elastic/obs-ux-logs-team +/x-pack/plugins/infra/server/routes @elastic/obs-ux-infra_services-team +/x-pack/plugins/infra/server/routes/log_analysis @elastic/obs-ux-logs-team +/x-pack/plugins/infra/server/routes/log_alerts @elastic/obs-ux-logs-team +/x-pack/plugins/infra/server/saved_objects/metrics_explorer_view @elastic/obs-ux-infra_services-team +/x-pack/plugins/infra/server/saved_objects/inventory_view @elastic/obs-ux-infra_services-team +/x-pack/plugins/infra/server/services @elastic/obs-ux-infra_services-team +/x-pack/plugins/infra/server/services/rules @elastic/obs-ux-infra_services-team @elastic/obs-ux-logs-team +/x-pack/plugins/infra/server/lib @elastic/obs-ux-infra_services-team +/x-pack/plugins/infra/server/lib/log_analysis @elastic/obs-ux-logs-team +/x-pack/plugins/infra/docs/state_machines @elastic/obs-ux-logs-team +/x-pack/plugins/infra/common/inventory_models @elastic/obs-ux-infra_services-team +/x-pack/plugins/infra/common/http_api/metrics_api.ts @elastic/obs-ux-infra_services-team +/x-pack/plugins/infra/common/http_api/snapshot_api.ts @elastic/obs-ux-infra_services-team +/x-pack/plugins/infra/common/http_api/log_analysis @elastic/obs-ux-logs-team +/x-pack/plugins/infra/common/http_api/metrics_explorer_views @elastic/obs-ux-infra_services-team +/x-pack/plugins/infra/common/http_api/host_details @elastic/obs-ux-infra_services-team +/x-pack/plugins/infra/common/http_api/log_alerts @elastic/obs-ux-logs-team +/x-pack/plugins/infra/common/snapshot_metric_i18n.ts @elastic/obs-ux-infra_services-team +/x-pack/plugins/infra/common/inventory_views @elastic/obs-ux-infra_services-team +/x-pack/plugins/infra/common/color_palette.test.ts @elastic/obs-ux-infra_services-team +/x-pack/plugins/infra/common/performance_tracing.ts @elastic/obs-ux-logs-team +/x-pack/plugins/infra/common/log_search_summary @elastic/obs-ux-logs-team +/x-pack/plugins/infra/common/metrics_sources @elastic/obs-ux-infra_services-team +/x-pack/plugins/infra/common/saved_views @elastic/obs-ux-infra_services-team +/x-pack/plugins/infra/common/infra_ml @elastic/obs-ux-infra_services-team +/x-pack/plugins/infra/common/formatters @elastic/obs-ux-infra_services-team +/x-pack/plugins/infra/common/log_text_scale @elastic/obs-ux-logs-team +/x-pack/plugins/infra/common/log_analysis @elastic/obs-ux-logs-team +/x-pack/plugins/infra/common/search_strategies/log_entries @elastic/obs-ux-logs-team +/x-pack/plugins/infra/common/metrics_explorer_views @elastic/obs-ux-infra_services-team +/x-pack/plugins/infra/common/source_configuration @elastic/obs-ux-infra_services-team +/x-pack/plugins/infra/common/color_palette.ts @elastic/obs-ux-infra_services-team +/x-pack/plugins/infra/common/log_search_result @elastic/obs-ux-logs-team +/x-pack/plugins/infra/public/apps/logs_app.tsx @elastic/obs-ux-logs-team +/x-pack/plugins/infra/public/apps/metrics_app.tsx @elastic/obs-ux-infra_services-team +/x-pack/plugins/infra/public/components/lens @elastic/obs-ux-infra_services-team +/x-pack/plugins/infra/public/components/try_it_button.tsx @elastic/obs-ux-infra_services-team +/x-pack/plugins/infra/public/components/fixed_datepicker.tsx +/x-pack/plugins/infra/public/components/logging @elastic/obs-ux-logs-team +/x-pack/plugins/infra/public/components/infrastructure_node_metrics_tables @elastic/obs-ux-infra_services-team +/x-pack/plugins/infra/public/components/saved_views @elastic/obs-ux-infra_services-team +/x-pack/plugins/infra/public/components/feature_feedback_button.tsx @elastic/obs-ux-infra_services-team +/x-pack/plugins/infra/public/components/log_stream @elastic/obs-ux-logs-team +/x-pack/plugins/infra/public/components/source_configuration @elastic/obs-ux-infra_services-team +/x-pack/plugins/infra/public/components/asset_details @elastic/obs-ux-infra_services-team +/x-pack/plugins/infra/public/containers/logs @elastic/obs-ux-logs-team +/x-pack/plugins/infra/public/containers/metrics_source @elastic/obs-ux-infra_services-team +/x-pack/plugins/infra/public/containers/metrics_explorer @elastic/obs-ux-infra_services-team +/x-pack/plugins/infra/public/containers/ml @elastic/obs-ux-infra_services-team +/x-pack/plugins/infra/public/pages/logs @elastic/obs-ux-logs-team +/x-pack/plugins/infra/public/pages/metrics @elastic/obs-ux-infra_services-team +/x-pack/plugins/infra/public/common @elastic/obs-ux-infra_services-team +/x-pack/plugins/infra/public/observability_logs @elastic/obs-ux-logs-team +/x-pack/plugins/infra/public/services @elastic/obs-ux-infra_services-team +/x-pack/test/functional/apps/infra @elastic/infra-monitoring-ui @elastic/obs-ux-infra_services-team @elastic/obs-ux-logs-team +/x-pack/test/api_integration/apis/infra @elastic/infra-monitoring-ui @elastic/obs-ux-infra_services-team # Elastic Stack Monitoring -/x-pack/test/functional/apps/monitoring @elastic/infra-monitoring-ui -/x-pack/test/api_integration/apis/monitoring @elastic/infra-monitoring-ui -/x-pack/test/api_integration/apis/monitoring_collection @elastic/infra-monitoring-ui -/x-pack/test_serverless/functional/test_suites/observability/observability_log_explorer @elastic/infra-monitoring-ui +/x-pack/test/functional/apps/monitoring @elastic/obs-ux-infra_services-team +/x-pack/test/api_integration/apis/monitoring @elastic/obs-ux-infra_services-team +/x-pack/test/api_integration/apis/monitoring_collection @elastic/obs-ux-infra_services-team +/x-pack/test_serverless/functional/test_suites/observability/observability_log_explorer @elastic/obs-ux-logs-team # Fleet /fleet_packages.json @elastic/fleet @@ -955,29 +1010,27 @@ x-pack/plugins/infra/server/lib/alerting @elastic/actionable-observability /x-pack/plugins/fleet/server/services/elastic_agent_manifest.ts @elastic/fleet @elastic/obs-cloudnative-monitoring # APM -/x-pack/test/functional/apps/apm/ @elastic/apm-ui -/x-pack/test/apm_api_integration/ @elastic/apm-ui +/x-pack/test/functional/apps/apm/ @elastic/obs-ux-infra_services-team +/x-pack/test/apm_api_integration/ @elastic/obs-ux-infra_services-team /src/apm.js @elastic/kibana-core @vigneshshanmugam -/src/core/types/elasticsearch @elastic/apm-ui /packages/kbn-utility-types/src/dot.ts @dgieselaar /packages/kbn-utility-types/src/dot_test.ts @dgieselaar #CC# /src/plugins/apm_oss/ @elastic/apm-ui #CC# /x-pack/plugins/observability/ @elastic/apm-ui # Uptime -/x-pack/test/functional_with_es_ssl/apps/discover_ml_uptime/uptime/ @elastic/uptime -/x-pack/test/functional/apps/uptime @elastic/uptime -/x-pack/test/functional/es_archives/uptime @elastic/uptime -/x-pack/test/functional/services/uptime @elastic/uptime -/x-pack/test/api_integration/apis/uptime @elastic/uptime -/x-pack/test/api_integration/apis/synthetics @elastic/uptime -/x-pack/test/alerting_api_integration/observability/synthetics_rule.ts @elastic/uptime -/x-pack/test/alerting_api_integration/observability/index.ts @elastic/uptime - -# Client Side Monitoring / Uptime (lives in APM directories but owned by Uptime) -/x-pack/plugins/apm/public/application/uxApp.tsx @elastic/uptime -/x-pack/plugins/apm/public/components/app/rum_dashboard @elastic/uptime -/x-pack/test/apm_api_integration/tests/csm/ @elastic/uptime +/x-pack/test/functional_with_es_ssl/apps/discover_ml_uptime/uptime/ @elastic/obs-ux-infra_services-team +/x-pack/test/functional/apps/uptime @elastic/obs-ux-infra_services-team +/x-pack/test/functional/es_archives/uptime @elastic/obs-ux-infra_services-team +/x-pack/test/functional/services/uptime @elastic/obs-ux-infra_services-team +/x-pack/test/api_integration/apis/uptime @elastic/obs-ux-infra_services-team +/x-pack/test/api_integration/apis/synthetics @elastic/obs-ux-infra_services-team +/x-pack/test/alerting_api_integration/observability/synthetics_rule.ts @elastic/obs-ux-infra_services-team +/x-pack/test/alerting_api_integration/observability/index.ts @elastic/obs-ux-management-team + +# Logs +/x-pack/test/api_integration/apis/logs_ui @elastic/obs-ux-logs-team +/x-pack/test/functional/apps/observability_log_explorer @elastic/obs-ux-logs-team # Observability onboarding tour /x-pack/plugins/observability_shared/public/components/tour @elastic/platform-onboarding @@ -1118,7 +1171,7 @@ x-pack/plugins/cloud_integrations/cloud_full_story/server/config.ts @elastic/kib # Response Ops team /x-pack/test/alerting_api_integration/ @elastic/response-ops -/x-pack/test/alerting_api_integration/observability @elastic/actionable-observability +/x-pack/test/alerting_api_integration/observability @elastic/obs-ux-management-team /x-pack/test/plugin_api_integration/test_suites/task_manager/ @elastic/response-ops /x-pack/test/functional_with_es_ssl/apps/triggers_actions_ui/ @elastic/response-ops /docs/user/alerting/ @elastic/response-ops @@ -1440,10 +1493,10 @@ x-pack/test/detection_engine_api_integration/security_and_spaces/group10/risk_en x-pack/plugins/translations/translations # Profiling api integration testing -x-pack/test/profiling_api_integration @elastic/profiling-ui +x-pack/test/profiling_api_integration @elastic/obs-ux-infra_services-team # Observability shared profiling -x-pack/plugins/observability_shared/public/components/profiling @elastic/profiling-ui +x-pack/plugins/observability_shared/public/components/profiling @elastic/obs-ux-infra_services-team # Shared UX packages/react @elastic/appex-sharedux diff --git a/package.json b/package.json index 3f3a05f840cb0..869529d6836a9 100644 --- a/package.json +++ b/package.json @@ -937,7 +937,7 @@ "json-stringify-safe": "5.0.1", "jsonwebtoken": "^9.0.0", "jsts": "^1.6.2", - "kea": "^2.4.2", + "kea": "^2.6.0", "langchain": "^0.0.151", "launchdarkly-js-client-sdk": "^3.1.4", "launchdarkly-node-server-sdk": "^7.0.3", @@ -1276,7 +1276,6 @@ "@storybook/react-docgen-typescript-plugin": "^1.0.1", "@storybook/testing-react": "^1.3.0", "@storybook/theming": "^6.5.16", - "@testing-library/dom": "^8.19.0", "@testing-library/jest-dom": "^5.16.5", "@testing-library/react": "^12.1.5", "@testing-library/react-hooks": "^8.0.1", diff --git a/packages/core/logging/core-logging-common-internal/src/layouts/conversions/message.test.ts b/packages/core/logging/core-logging-common-internal/src/layouts/conversions/message.test.ts index cf16b57c92782..2c84635d6711c 100644 --- a/packages/core/logging/core-logging-common-internal/src/layouts/conversions/message.test.ts +++ b/packages/core/logging/core-logging-common-internal/src/layouts/conversions/message.test.ts @@ -62,4 +62,52 @@ describe('MessageConversion', () => { '\\u001b\\u0000[31mESC-INJECTION-LFUNICODE:\\u001b[32mSUCCESSFUL\\u001b[0m\\u0007\n\nInjecting 10.000 lols 😂\\u001b[10000;b\\u0007' ); }); + + test('it should encode/escape ANSI chars lines from the message when not a string', () => { + expect( + MessageConversion.convert( + { + ...baseRecord, + // @ts-expect-error message is supposed to be a string + message: { + toString: () => 'toString...\u001b[5;7;6mThis is Fine\u001b[27m', + }, + }, + false + ) + ).toEqual('toString...\\u001b[5;7;6mThis is Fine\\u001b[27m'); + }); + + test('it should encode/escape ANSI chars lines from the error stack', () => { + const error = new Error('Something went bad'); + error.stack = 'stack...\u001b[5;7;6mThis is Fine\u001b[27m'; + expect( + MessageConversion.convert( + { + ...baseRecord, + message: 'Some message that will be ignored', + error, + }, + false + ) + ).toEqual('stack...\\u001b[5;7;6mThis is Fine\\u001b[27m'); + }); + + test('it should encode/escape ANSI chars lines from the error stack when not a string', () => { + expect( + MessageConversion.convert( + { + ...baseRecord, + message: 'Some message that will be ignored', + error: { + // @ts-expect-error message is supposed to be a string + stack: { + toString: () => 'stackToString...\u001b[5;7;6mThis is Fine\u001b[27m', + }, + }, + }, + false + ) + ).toEqual('stackToString...\\u001b[5;7;6mThis is Fine\\u001b[27m'); + }); }); diff --git a/packages/core/logging/core-logging-common-internal/src/layouts/conversions/message.ts b/packages/core/logging/core-logging-common-internal/src/layouts/conversions/message.ts index 706aa478d992b..1d0dd15373aaf 100644 --- a/packages/core/logging/core-logging-common-internal/src/layouts/conversions/message.ts +++ b/packages/core/logging/core-logging-common-internal/src/layouts/conversions/message.ts @@ -17,17 +17,19 @@ export const MessageConversion: Conversion = { pattern: /%message/g, convert(record: LogRecord) { // Error stack is much more useful than just the message. - const str = record.error?.stack || record.message; + let str = record.error?.stack || record.message; + // typings may be wrong, there's scenarios where the message is not a plain string (e.g error stacks from the ES client) + if (typeof str !== 'string') { + str = String(str); + } - return typeof str === 'string' // We need to validate it's a string because, despite types, there are use case where it's not a string :/ - ? str.replace( - CONTROL_CHAR_REGEXP, - // Escaping control chars via JSON.stringify to maintain consistency with `meta` and the JSON layout. - // This way, post analysis of the logs is easier as we can search the same patterns. - // Our benchmark didn't show a big difference in performance between custom-escaping vs. JSON.stringify one. - // The slice is removing the double-quotes. - (substr) => JSON.stringify(substr).slice(1, -1) - ) - : str; + return str.replace( + CONTROL_CHAR_REGEXP, + // Escaping control chars via JSON.stringify to maintain consistency with `meta` and the JSON layout. + // This way, post analysis of the logs is easier as we can search the same patterns. + // Our benchmark didn't show a big difference in performance between custom-escaping vs. JSON.stringify one. + // The slice is removing the double-quotes. + (substr) => JSON.stringify(substr).slice(1, -1) + ); }, }; diff --git a/packages/deeplinks/observability/kibana.jsonc b/packages/deeplinks/observability/kibana.jsonc index 4a93ff4427da8..bc014b05aa407 100644 --- a/packages/deeplinks/observability/kibana.jsonc +++ b/packages/deeplinks/observability/kibana.jsonc @@ -1,5 +1,5 @@ { "type": "shared-common", "id": "@kbn/deeplinks-observability", - "owner": "@elastic/apm-ui" + "owner": "@elastic/obs-ux-logs-team" } diff --git a/packages/kbn-apm-synthtrace-client/kibana.jsonc b/packages/kbn-apm-synthtrace-client/kibana.jsonc index b9f2d79601d6d..99055f3da4fe9 100644 --- a/packages/kbn-apm-synthtrace-client/kibana.jsonc +++ b/packages/kbn-apm-synthtrace-client/kibana.jsonc @@ -2,5 +2,5 @@ "type": "shared-common", "id": "@kbn/apm-synthtrace-client", "devOnly": true, - "owner": "@elastic/apm-ui" + "owner": "@elastic/obs-ux-infra_services-team" } diff --git a/packages/kbn-apm-synthtrace/kibana.jsonc b/packages/kbn-apm-synthtrace/kibana.jsonc index c1efc5fd09c00..1b3ef5b846149 100644 --- a/packages/kbn-apm-synthtrace/kibana.jsonc +++ b/packages/kbn-apm-synthtrace/kibana.jsonc @@ -2,5 +2,5 @@ "type": "shared-server", "id": "@kbn/apm-synthtrace", "devOnly": true, - "owner": "@elastic/apm-ui" + "owner": "@elastic/obs-ux-infra_services-team" } diff --git a/packages/kbn-apm-utils/kibana.jsonc b/packages/kbn-apm-utils/kibana.jsonc index 950a5dacb9ba8..2ee2a3b45335a 100644 --- a/packages/kbn-apm-utils/kibana.jsonc +++ b/packages/kbn-apm-utils/kibana.jsonc @@ -1,5 +1,5 @@ { "type": "shared-common", "id": "@kbn/apm-utils", - "owner": "@elastic/apm-ui" + "owner": "@elastic/obs-ux-infra_services-team" } diff --git a/packages/kbn-cell-actions/src/hooks/use_data_grid_column_cell_actions.test.tsx b/packages/kbn-cell-actions/src/hooks/use_data_grid_column_cell_actions.test.tsx index 136ca441588f4..014cb526c81fe 100644 --- a/packages/kbn-cell-actions/src/hooks/use_data_grid_column_cell_actions.test.tsx +++ b/packages/kbn-cell-actions/src/hooks/use_data_grid_column_cell_actions.test.tsx @@ -13,8 +13,8 @@ import { EuiDataGridRefProps, type EuiDataGridColumnCellAction, } from '@elastic/eui'; -import { render, waitFor } from '@testing-library/react'; -import { act, renderHook } from '@testing-library/react-hooks'; +import { render, waitFor, act } from '@testing-library/react'; +import { renderHook } from '@testing-library/react-hooks'; import { makeAction } from '../mocks/helpers'; import { useDataGridColumnsCellActions, diff --git a/packages/kbn-custom-integrations/kibana.jsonc b/packages/kbn-custom-integrations/kibana.jsonc index 61c9067c7e659..995d5bb4ef69d 100644 --- a/packages/kbn-custom-integrations/kibana.jsonc +++ b/packages/kbn-custom-integrations/kibana.jsonc @@ -1,5 +1,5 @@ { "type": "shared-common", "id": "@kbn/custom-integrations", - "owner": "@elastic/infra-monitoring-ui" + "owner": "@elastic/obs-ux-logs-team" } diff --git a/packages/kbn-es-types/kibana.jsonc b/packages/kbn-es-types/kibana.jsonc index 1c00cab81d2c4..2435d7666cf9a 100644 --- a/packages/kbn-es-types/kibana.jsonc +++ b/packages/kbn-es-types/kibana.jsonc @@ -1,5 +1,5 @@ { "type": "shared-common", "id": "@kbn/es-types", - "owner": ["@elastic/kibana-core", "@elastic/apm-ui"] + "owner": ["@elastic/kibana-core", "@elastic/obs-knowledge-team"] } diff --git a/packages/kbn-eslint-plugin-i18n/kibana.jsonc b/packages/kbn-eslint-plugin-i18n/kibana.jsonc index 7d8c994400108..72e051941db68 100644 --- a/packages/kbn-eslint-plugin-i18n/kibana.jsonc +++ b/packages/kbn-eslint-plugin-i18n/kibana.jsonc @@ -1,6 +1,6 @@ { "type": "shared-common", "id": "@kbn/eslint-plugin-i18n", - "owner": "@elastic/actionable-observability", + "owner": "@elastic/obs-knowledge-team", "devOnly": true } diff --git a/packages/kbn-eslint-plugin-telemetry/kibana.jsonc b/packages/kbn-eslint-plugin-telemetry/kibana.jsonc index 79c8fbf8adb2b..e3c245a5275d8 100644 --- a/packages/kbn-eslint-plugin-telemetry/kibana.jsonc +++ b/packages/kbn-eslint-plugin-telemetry/kibana.jsonc @@ -1,6 +1,6 @@ { "type": "shared-common", "id": "@kbn/eslint-plugin-telemetry", - "owner": "@elastic/actionable-observability", + "owner": "@elastic/obs-knowledge-team", "devOnly": true } diff --git a/packages/kbn-io-ts-utils/kibana.jsonc b/packages/kbn-io-ts-utils/kibana.jsonc index 7d03717a53153..ea3032a472dc6 100644 --- a/packages/kbn-io-ts-utils/kibana.jsonc +++ b/packages/kbn-io-ts-utils/kibana.jsonc @@ -1,5 +1,5 @@ { "type": "shared-common", "id": "@kbn/io-ts-utils", - "owner": "@elastic/apm-ui" + "owner": "@elastic/obs-knowledge-team" } diff --git a/packages/kbn-lens-embeddable-utils/kibana.jsonc b/packages/kbn-lens-embeddable-utils/kibana.jsonc index d637ea2f24ccb..9dc67508d99e9 100644 --- a/packages/kbn-lens-embeddable-utils/kibana.jsonc +++ b/packages/kbn-lens-embeddable-utils/kibana.jsonc @@ -1,5 +1,5 @@ { "type": "shared-browser", "id": "@kbn/lens-embeddable-utils", - "owner": "@elastic/infra-monitoring-ui" + "owner": "@elastic/obs-ux-infra_services-team" } diff --git a/packages/kbn-profiling-utils/kibana.jsonc b/packages/kbn-profiling-utils/kibana.jsonc index dc45e822e620b..d41a4db71299d 100644 --- a/packages/kbn-profiling-utils/kibana.jsonc +++ b/packages/kbn-profiling-utils/kibana.jsonc @@ -1,5 +1,5 @@ { "type": "shared-common", "id": "@kbn/profiling-utils", - "owner": "@elastic/profiling-ui" + "owner": "@elastic/obs-ux-infra_services-team" } diff --git a/packages/kbn-resizable-layout/src/panels_resizable.test.tsx b/packages/kbn-resizable-layout/src/panels_resizable.test.tsx index 3ea2ccc87aaeb..f3ebde2aa73ed 100644 --- a/packages/kbn-resizable-layout/src/panels_resizable.test.tsx +++ b/packages/kbn-resizable-layout/src/panels_resizable.test.tsx @@ -24,7 +24,7 @@ jest.mock('@elastic/eui', () => ({ })); import * as eui from '@elastic/eui'; -import { waitFor } from '@testing-library/dom'; +import { waitFor } from '@testing-library/react'; import { ResizableLayoutDirection } from '../types'; describe('Panels resizable', () => { diff --git a/packages/kbn-rule-data-utils/kibana.jsonc b/packages/kbn-rule-data-utils/kibana.jsonc index 6650a9b1d67f0..4d9d77fbeeb72 100644 --- a/packages/kbn-rule-data-utils/kibana.jsonc +++ b/packages/kbn-rule-data-utils/kibana.jsonc @@ -3,7 +3,7 @@ "id": "@kbn/rule-data-utils", "owner": [ "@elastic/security-detections-response", - "@elastic/actionable-observability", - "@elastic/response-ops" + "@elastic/response-ops", + "@elastic/obs-ux-management-team" ] } diff --git a/packages/kbn-securitysolution-exception-list-components/src/list_header/use_list_header.test.ts b/packages/kbn-securitysolution-exception-list-components/src/list_header/use_list_header.test.ts index 9ddd782e132cd..867ad6ce8e3e6 100644 --- a/packages/kbn-securitysolution-exception-list-components/src/list_header/use_list_header.test.ts +++ b/packages/kbn-securitysolution-exception-list-components/src/list_header/use_list_header.test.ts @@ -5,7 +5,7 @@ * in compliance with, at your election, the Elastic License 2.0 or the Server * Side Public License, v 1. */ -import { waitFor } from '@testing-library/dom'; +import { waitFor } from '@testing-library/react'; import { act, renderHook } from '@testing-library/react-hooks'; import { useExceptionListHeader } from './use_list_header'; diff --git a/packages/kbn-server-route-repository/kibana.jsonc b/packages/kbn-server-route-repository/kibana.jsonc index 8161be4b80951..dbf7fc396428c 100644 --- a/packages/kbn-server-route-repository/kibana.jsonc +++ b/packages/kbn-server-route-repository/kibana.jsonc @@ -1,5 +1,5 @@ { "type": "shared-common", "id": "@kbn/server-route-repository", - "owner": "@elastic/apm-ui" + "owner": ["@elastic/obs-knowledge-team", "@elastic/obs-ux-management-team"] } diff --git a/packages/kbn-shared-svg/kibana.jsonc b/packages/kbn-shared-svg/kibana.jsonc index 6634bd9dffc5d..89949f5b7d276 100644 --- a/packages/kbn-shared-svg/kibana.jsonc +++ b/packages/kbn-shared-svg/kibana.jsonc @@ -1,5 +1,5 @@ { "type": "shared-common", "id": "@kbn/shared-svg", - "owner": "@elastic/apm-ui" + "owner": "@elastic/obs-ux-infra_services-team" } diff --git a/packages/kbn-typed-react-router-config/kibana.jsonc b/packages/kbn-typed-react-router-config/kibana.jsonc index f508346f8c26e..0462d28238890 100644 --- a/packages/kbn-typed-react-router-config/kibana.jsonc +++ b/packages/kbn-typed-react-router-config/kibana.jsonc @@ -1,5 +1,5 @@ { "type": "shared-common", "id": "@kbn/typed-react-router-config", - "owner": "@elastic/apm-ui" + "owner": ["@elastic/obs-knowledge-team", "@elastic/obs-ux-management-team"] } diff --git a/packages/kbn-use-tracked-promise/kibana.jsonc b/packages/kbn-use-tracked-promise/kibana.jsonc index a7b90045c462a..959dda0d05a66 100644 --- a/packages/kbn-use-tracked-promise/kibana.jsonc +++ b/packages/kbn-use-tracked-promise/kibana.jsonc @@ -1,5 +1,5 @@ { "type": "shared-common", "id": "@kbn/use-tracked-promise", - "owner": "@elastic/infra-monitoring-ui" + "owner": "@elastic/obs-ux-logs-team" } diff --git a/packages/kbn-xstate-utils/kibana.jsonc b/packages/kbn-xstate-utils/kibana.jsonc index 086bce23401aa..cd1151a3f2103 100644 --- a/packages/kbn-xstate-utils/kibana.jsonc +++ b/packages/kbn-xstate-utils/kibana.jsonc @@ -1,5 +1,5 @@ { "type": "shared-common", "id": "@kbn/xstate-utils", - "owner": "@elastic/infra-monitoring-ui" + "owner": "@elastic/obs-ux-logs-team" } diff --git a/packages/serverless/settings/observability_project/kibana.jsonc b/packages/serverless/settings/observability_project/kibana.jsonc index 4df29091e6619..e2db00d894bcf 100644 --- a/packages/serverless/settings/observability_project/kibana.jsonc +++ b/packages/serverless/settings/observability_project/kibana.jsonc @@ -1,5 +1,5 @@ { "type": "shared-common", "id": "@kbn/serverless-observability-settings", - "owner": "@elastic/appex-sharedux @elastic/apm-ui @elastic/platform-deployment-management" + "owner": "@elastic/appex-sharedux @elastic/platform-deployment-management @elastic/obs-ux-management-team" } diff --git a/src/cli/dist.js b/src/cli/dist.js index 9bd7696a44561..5551c4e5c7774 100644 --- a/src/cli/dist.js +++ b/src/cli/dist.js @@ -9,4 +9,5 @@ require('../setup_node_env/dist'); require('./apm')(); require('../setup_node_env/root'); +require('../setup_node_env/mute_libraries'); require('./cli'); diff --git a/src/dev/build/tasks/os_packages/docker_generator/templates/base/Dockerfile b/src/dev/build/tasks/os_packages/docker_generator/templates/base/Dockerfile index 8db4b419a184a..25f4345ffbcc3 100644 --- a/src/dev/build/tasks/os_packages/docker_generator/templates/base/Dockerfile +++ b/src/dev/build/tasks/os_packages/docker_generator/templates/base/Dockerfile @@ -128,6 +128,7 @@ COPY --chown=1000:0 config/serverless.oblt.yml /usr/share/kibana/config/serverle COPY --chown=1000:0 config/serverless.security.yml /usr/share/kibana/config/serverless.security.yml # Supportability enhancement: enable capturing heap snapshots. See https://nodejs.org/api/cli.html#--heapsnapshot-signalsignal RUN echo '\n--heapsnapshot-signal=SIGUSR2' >> config/node.options +RUN echo '--diagnostic-dir=./data' >> config/node.options {{/serverless}} {{^opensslLegacyProvider}} RUN sed 's/\(--openssl-legacy-provider\)/#\1/' -i config/node.options diff --git a/src/plugins/embeddable/public/lib/embeddables/embeddable_renderer.test.tsx b/src/plugins/embeddable/public/lib/embeddables/embeddable_renderer.test.tsx index b919672ad01e3..a1be9c560bf3c 100644 --- a/src/plugins/embeddable/public/lib/embeddables/embeddable_renderer.test.tsx +++ b/src/plugins/embeddable/public/lib/embeddables/embeddable_renderer.test.tsx @@ -7,7 +7,7 @@ */ import React from 'react'; -import { waitFor } from '@testing-library/dom'; +import { waitFor } from '@testing-library/react'; import { render } from '@testing-library/react'; import { renderHook } from '@testing-library/react-hooks'; import { diff --git a/src/plugins/ui_actions/public/context_menu/open_context_menu.test.ts b/src/plugins/ui_actions/public/context_menu/open_context_menu.test.ts index f8b54fb33e122..ddd7d77812add 100644 --- a/src/plugins/ui_actions/public/context_menu/open_context_menu.test.ts +++ b/src/plugins/ui_actions/public/context_menu/open_context_menu.test.ts @@ -7,7 +7,7 @@ */ import { createInteractionPositionTracker } from './open_context_menu'; -import { fireEvent } from '@testing-library/dom'; +import { fireEvent } from '@testing-library/react'; let targetEl: Element; const top = 100; diff --git a/src/plugins/ui_actions/public/tests/execute_trigger_actions.test.ts b/src/plugins/ui_actions/public/tests/execute_trigger_actions.test.ts index 950c70ec7c60d..ea9d343845442 100644 --- a/src/plugins/ui_actions/public/tests/execute_trigger_actions.test.ts +++ b/src/plugins/ui_actions/public/tests/execute_trigger_actions.test.ts @@ -10,7 +10,7 @@ import { ActionDefinition } from '../actions'; import { openContextMenu } from '../context_menu'; import { uiActionsPluginMock } from '../mocks'; import type { Trigger } from '@kbn/ui-actions-browser'; -import { waitFor } from '@testing-library/dom'; +import { waitFor } from '@testing-library/react'; jest.mock('../context_menu'); diff --git a/src/plugins/unified_histogram/public/chart/hooks/use_total_hits.test.ts b/src/plugins/unified_histogram/public/chart/hooks/use_total_hits.test.ts index e6f3aeaa3a002..3135f3c86f465 100644 --- a/src/plugins/unified_histogram/public/chart/hooks/use_total_hits.test.ts +++ b/src/plugins/unified_histogram/public/chart/hooks/use_total_hits.test.ts @@ -15,7 +15,7 @@ import { renderHook } from '@testing-library/react-hooks'; import { dataPluginMock } from '@kbn/data-plugin/public/mocks'; import { searchSourceInstanceMock } from '@kbn/data-plugin/common/search/search_source/mocks'; import { of, Subject, throwError } from 'rxjs'; -import { waitFor } from '@testing-library/dom'; +import { waitFor } from '@testing-library/react'; import { RequestAdapter } from '@kbn/inspector-plugin/common'; import { DataViewType, SearchSourceSearchOptions } from '@kbn/data-plugin/common'; import { expressionsPluginMock } from '@kbn/expressions-plugin/public/mocks'; diff --git a/src/plugins/unified_search/public/query_string_input/query_string_input.test.tsx b/src/plugins/unified_search/public/query_string_input/query_string_input.test.tsx index 8e60c720e1154..aa348d59d85f4 100644 --- a/src/plugins/unified_search/public/query_string_input/query_string_input.test.tsx +++ b/src/plugins/unified_search/public/query_string_input/query_string_input.test.tsx @@ -15,8 +15,7 @@ import { import React from 'react'; import { I18nProvider } from '@kbn/i18n-react'; import { mount } from 'enzyme'; -import { waitFor } from '@testing-library/dom'; -import { render } from '@testing-library/react'; +import { waitFor, render } from '@testing-library/react'; import { EuiTextArea, EuiIcon } from '@elastic/eui'; diff --git a/src/setup_node_env/heap_snapshot.js b/src/setup_node_env/heap_snapshot.js new file mode 100644 index 0000000000000..94e4b35e2f887 --- /dev/null +++ b/src/setup_node_env/heap_snapshot.js @@ -0,0 +1,46 @@ +/* + * Copyright Elasticsearch B.V. and/or licensed to Elasticsearch B.V. under one + * or more contributor license agreements. Licensed under the Elastic License + * 2.0 and the Server Side Public License, v 1; you may not use this file except + * in compliance with, at your election, the Elastic License 2.0 or the Server + * Side Public License, v 1. + */ + +var getopts = require('getopts'); +var path = require('path'); +var v8 = require('node:v8'); +var worker = require('node:worker_threads'); + +var execOpts = getopts(process.execArgv); +var envOpts = getopts(process.env.NODE_OPTIONS ? process.env.NODE_OPTIONS.split(/\s+/) : []); +var diagnosticDir = execOpts['diagnostic-dir'] || envOpts['diagnostic-dir']; +var heapSnapshotSignal = execOpts['heapsnapshot-signal'] || envOpts['heapsnapshot-signal']; +var heapSnapshotSerial = 0; + +function getHeapSnapshotPath() { + var now = new Date(); + + var year = now.getFullYear(); + var month = String(now.getMonth() + 1).padStart(2, '0'); + var day = String(now.getDate()).padStart(2, '0'); + var hours = String(now.getHours()).padStart(2, '0'); + var minutes = String(now.getMinutes()).padStart(2, '0'); + var seconds = String(now.getSeconds()).padStart(2, '0'); + + var date = `${year}${month}${day}`; + var time = `${hours}${minutes}${seconds}`; + var pid = process.pid; + var threadId = worker.threadId; + var serial = (++heapSnapshotSerial).toString().padStart(3, '0'); + + return path.join(diagnosticDir, `Heap.${date}.${time}.${pid}.${threadId}.${serial}.heapsnapshot`); +} + +if (diagnosticDir && heapSnapshotSignal) { + process.removeAllListeners(heapSnapshotSignal); + + process.on(heapSnapshotSignal, function () { + var heapSnapshotPath = getHeapSnapshotPath(); + v8.writeHeapSnapshot(heapSnapshotPath); + }); +} diff --git a/src/setup_node_env/mute_libraries.js b/src/setup_node_env/mute_libraries.js new file mode 100644 index 0000000000000..defb6347d80f7 --- /dev/null +++ b/src/setup_node_env/mute_libraries.js @@ -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 and the Server Side Public License, v 1; you may not use this file except + * in compliance with, at your election, the Elastic License 2.0 or the Server + * Side Public License, v 1. + */ + +// disable moment deprecation warnings +var moment = require('moment'); +moment.suppressDeprecationWarnings = true; diff --git a/src/setup_node_env/setup_env.js b/src/setup_node_env/setup_env.js index 7b37d98011cfb..d3076a2c3b9cf 100644 --- a/src/setup_node_env/setup_env.js +++ b/src/setup_node_env/setup_env.js @@ -11,6 +11,8 @@ require('./exit_on_warning'); require('./harden'); // The following require statements MUST be executed before any others - END +// @todo Remove when migrated to Node 20 (#162696) +require('./heap_snapshot'); require('symbol-observable'); require('source-map-support').install(); require('./node_version_validator'); diff --git a/test/common/plugins/otel_metrics/kibana.jsonc b/test/common/plugins/otel_metrics/kibana.jsonc index 0b25b57d06a53..e64546f446052 100644 --- a/test/common/plugins/otel_metrics/kibana.jsonc +++ b/test/common/plugins/otel_metrics/kibana.jsonc @@ -1,7 +1,7 @@ { "type": "plugin", "id": "@kbn/open-telemetry-instrumented-plugin", - "owner": "@elastic/infra-monitoring-ui", + "owner": "@elastic/obs-ux-infra_services-team", "plugin": { "id": "openTelemetryInstrumentedPlugin", "server": true, diff --git a/x-pack/examples/exploratory_view_example/kibana.jsonc b/x-pack/examples/exploratory_view_example/kibana.jsonc index c524e4fda32f7..6cf8fa64983ac 100644 --- a/x-pack/examples/exploratory_view_example/kibana.jsonc +++ b/x-pack/examples/exploratory_view_example/kibana.jsonc @@ -1,7 +1,7 @@ { "type": "plugin", "id": "@kbn/exploratory-view-example-plugin", - "owner": "@elastic/uptime", + "owner": "@elastic/obs-ux-infra_services-team", "plugin": { "id": "exploratoryViewExample", "server": false, diff --git a/x-pack/packages/kbn-infra-forge/kibana.jsonc b/x-pack/packages/kbn-infra-forge/kibana.jsonc index a66a733662735..a450d148358a9 100644 --- a/x-pack/packages/kbn-infra-forge/kibana.jsonc +++ b/x-pack/packages/kbn-infra-forge/kibana.jsonc @@ -1,5 +1,5 @@ { "type": "shared-common", "id": "@kbn/infra-forge", - "owner": "@elastic/actionable-observability" + "owner": "@elastic/obs-ux-management-team" } diff --git a/x-pack/packages/kbn-slo-schema/kibana.jsonc b/x-pack/packages/kbn-slo-schema/kibana.jsonc index 2d12cd108585c..b4ca324fc112b 100644 --- a/x-pack/packages/kbn-slo-schema/kibana.jsonc +++ b/x-pack/packages/kbn-slo-schema/kibana.jsonc @@ -1,5 +1,5 @@ { "type": "shared-common", "id": "@kbn/slo-schema", - "owner": "@elastic/actionable-observability", + "owner": "@elastic/obs-ux-management-team" } diff --git a/x-pack/packages/security-solution/navigation/src/navigation.test.ts b/x-pack/packages/security-solution/navigation/src/navigation.test.ts index ab9ab891aaef8..a4290563476ea 100644 --- a/x-pack/packages/security-solution/navigation/src/navigation.test.ts +++ b/x-pack/packages/security-solution/navigation/src/navigation.test.ts @@ -7,7 +7,7 @@ import { useGetAppUrl, useNavigateTo } from './navigation'; import { mockGetUrlForApp, mockNavigateToApp, mockNavigateToUrl } from '../mocks/context'; import { renderHook } from '@testing-library/react-hooks'; -import { fireEvent } from '@testing-library/dom'; +import { fireEvent } from '@testing-library/react'; jest.mock('./context'); diff --git a/x-pack/plugins/alerting/public/hooks/use_archive_maintenance_window.test.tsx b/x-pack/plugins/alerting/public/hooks/use_archive_maintenance_window.test.tsx index e6bd2a4071b27..d72f0bda9dc93 100644 --- a/x-pack/plugins/alerting/public/hooks/use_archive_maintenance_window.test.tsx +++ b/x-pack/plugins/alerting/public/hooks/use_archive_maintenance_window.test.tsx @@ -5,7 +5,7 @@ * 2.0. */ import { act, renderHook } from '@testing-library/react-hooks/dom'; -import { waitFor } from '@testing-library/dom'; +import { waitFor } from '@testing-library/react'; import { MaintenanceWindow } from '../pages/maintenance_windows/types'; import { AppMockRenderer, createAppMockRenderer } from '../lib/test_utils'; diff --git a/x-pack/plugins/alerting/public/hooks/use_create_maintenance_window.test.tsx b/x-pack/plugins/alerting/public/hooks/use_create_maintenance_window.test.tsx index 195af1bb083e5..f827287532445 100644 --- a/x-pack/plugins/alerting/public/hooks/use_create_maintenance_window.test.tsx +++ b/x-pack/plugins/alerting/public/hooks/use_create_maintenance_window.test.tsx @@ -5,7 +5,7 @@ * 2.0. */ import { act, renderHook } from '@testing-library/react-hooks/dom'; -import { waitFor } from '@testing-library/dom'; +import { waitFor } from '@testing-library/react'; import { MaintenanceWindow } from '../pages/maintenance_windows/types'; import { AppMockRenderer, createAppMockRenderer } from '../lib/test_utils'; diff --git a/x-pack/plugins/alerting/public/hooks/use_find_maintenance_windows.test.tsx b/x-pack/plugins/alerting/public/hooks/use_find_maintenance_windows.test.tsx index 2080b9ff39d43..d21b145aea937 100644 --- a/x-pack/plugins/alerting/public/hooks/use_find_maintenance_windows.test.tsx +++ b/x-pack/plugins/alerting/public/hooks/use_find_maintenance_windows.test.tsx @@ -5,7 +5,7 @@ * 2.0. */ import { renderHook } from '@testing-library/react-hooks/dom'; -import { waitFor } from '@testing-library/dom'; +import { waitFor } from '@testing-library/react'; import { AppMockRenderer, createAppMockRenderer } from '../lib/test_utils'; import { useFindMaintenanceWindows } from './use_find_maintenance_windows'; diff --git a/x-pack/plugins/alerting/public/hooks/use_finish_and_archive_maintenance_window.test.tsx b/x-pack/plugins/alerting/public/hooks/use_finish_and_archive_maintenance_window.test.tsx index b80dbbae355bc..453a3b88cef8f 100644 --- a/x-pack/plugins/alerting/public/hooks/use_finish_and_archive_maintenance_window.test.tsx +++ b/x-pack/plugins/alerting/public/hooks/use_finish_and_archive_maintenance_window.test.tsx @@ -5,7 +5,7 @@ * 2.0. */ import { act, renderHook } from '@testing-library/react-hooks/dom'; -import { waitFor } from '@testing-library/dom'; +import { waitFor } from '@testing-library/react'; import { MaintenanceWindow } from '../pages/maintenance_windows/types'; import { AppMockRenderer, createAppMockRenderer } from '../lib/test_utils'; diff --git a/x-pack/plugins/alerting/public/hooks/use_finish_maintenance_window.test.tsx b/x-pack/plugins/alerting/public/hooks/use_finish_maintenance_window.test.tsx index ed534cb835c8d..06608125fd836 100644 --- a/x-pack/plugins/alerting/public/hooks/use_finish_maintenance_window.test.tsx +++ b/x-pack/plugins/alerting/public/hooks/use_finish_maintenance_window.test.tsx @@ -5,7 +5,7 @@ * 2.0. */ import { act, renderHook } from '@testing-library/react-hooks/dom'; -import { waitFor } from '@testing-library/dom'; +import { waitFor } from '@testing-library/react'; import { MaintenanceWindow } from '../pages/maintenance_windows/types'; import { AppMockRenderer, createAppMockRenderer } from '../lib/test_utils'; diff --git a/x-pack/plugins/alerting/public/hooks/use_get_maintenance_window.test.tsx b/x-pack/plugins/alerting/public/hooks/use_get_maintenance_window.test.tsx index eaef1f4fc4b99..3003f1003ce12 100644 --- a/x-pack/plugins/alerting/public/hooks/use_get_maintenance_window.test.tsx +++ b/x-pack/plugins/alerting/public/hooks/use_get_maintenance_window.test.tsx @@ -5,7 +5,7 @@ * 2.0. */ import { renderHook } from '@testing-library/react-hooks/dom'; -import { waitFor } from '@testing-library/dom'; +import { waitFor } from '@testing-library/react'; import { AppMockRenderer, createAppMockRenderer } from '../lib/test_utils'; import { useGetMaintenanceWindow } from './use_get_maintenance_window'; diff --git a/x-pack/plugins/alerting/public/hooks/use_update_maintenance_window.test.tsx b/x-pack/plugins/alerting/public/hooks/use_update_maintenance_window.test.tsx index 897b44295d8c0..b29161f0e006d 100644 --- a/x-pack/plugins/alerting/public/hooks/use_update_maintenance_window.test.tsx +++ b/x-pack/plugins/alerting/public/hooks/use_update_maintenance_window.test.tsx @@ -5,7 +5,7 @@ * 2.0. */ import { act, renderHook } from '@testing-library/react-hooks/dom'; -import { waitFor } from '@testing-library/dom'; +import { waitFor } from '@testing-library/react'; import { MaintenanceWindow } from '../pages/maintenance_windows/types'; import { AppMockRenderer, createAppMockRenderer } from '../lib/test_utils'; diff --git a/x-pack/plugins/alerting/public/pages/maintenance_windows/components/status_filter.test.tsx b/x-pack/plugins/alerting/public/pages/maintenance_windows/components/status_filter.test.tsx index f7cb8023323ef..3875545e36df4 100644 --- a/x-pack/plugins/alerting/public/pages/maintenance_windows/components/status_filter.test.tsx +++ b/x-pack/plugins/alerting/public/pages/maintenance_windows/components/status_filter.test.tsx @@ -6,7 +6,7 @@ */ import { Query } from '@elastic/eui'; -import { fireEvent } from '@testing-library/dom'; +import { fireEvent } from '@testing-library/react'; import React from 'react'; import { AppMockRenderer, createAppMockRenderer } from '../../../lib/test_utils'; diff --git a/x-pack/plugins/alerting/public/pages/maintenance_windows/components/table_actions_popover.test.tsx b/x-pack/plugins/alerting/public/pages/maintenance_windows/components/table_actions_popover.test.tsx index 2b1a1057084f5..8da3e12847e3a 100644 --- a/x-pack/plugins/alerting/public/pages/maintenance_windows/components/table_actions_popover.test.tsx +++ b/x-pack/plugins/alerting/public/pages/maintenance_windows/components/table_actions_popover.test.tsx @@ -5,7 +5,7 @@ * 2.0. */ -import { fireEvent } from '@testing-library/dom'; +import { fireEvent } from '@testing-library/react'; import React from 'react'; import { AppMockRenderer, createAppMockRenderer } from '../../../lib/test_utils'; diff --git a/x-pack/plugins/apm/kibana.jsonc b/x-pack/plugins/apm/kibana.jsonc index 61ba6be743370..858cd142f399c 100644 --- a/x-pack/plugins/apm/kibana.jsonc +++ b/x-pack/plugins/apm/kibana.jsonc @@ -1,7 +1,7 @@ { "type": "plugin", "id": "@kbn/apm-plugin", - "owner": "@elastic/apm-ui", + "owner": "@elastic/obs-ux-infra_services-team", "description": "The user interface for Elastic APM", "plugin": { "id": "apm", diff --git a/x-pack/plugins/apm_data_access/kibana.jsonc b/x-pack/plugins/apm_data_access/kibana.jsonc index d0ee0befda101..ede5cd53c9a6c 100644 --- a/x-pack/plugins/apm_data_access/kibana.jsonc +++ b/x-pack/plugins/apm_data_access/kibana.jsonc @@ -1,7 +1,7 @@ { "type": "plugin", "id": "@kbn/apm-data-access-plugin", - "owner": "@elastic/apm-ui", + "owner": ["@elastic/obs-knowledge-team", "@elastic/obs-ux-infra_services-team"], "plugin": { "id": "apmDataAccess", "server": true, diff --git a/x-pack/plugins/asset_manager/kibana.jsonc b/x-pack/plugins/asset_manager/kibana.jsonc index b3fcd1b3a4fa1..1ee4b12d55ea7 100644 --- a/x-pack/plugins/asset_manager/kibana.jsonc +++ b/x-pack/plugins/asset_manager/kibana.jsonc @@ -1,7 +1,7 @@ { "type": "plugin", "id": "@kbn/assetManager-plugin", - "owner": "@elastic/infra-monitoring-ui", + "owner": "@elastic/obs-knowledge-team", "description": "Asset manager plugin for entity assets (inventory, topology, etc)", "plugin": { "id": "assetManager", diff --git a/x-pack/plugins/cases/docs/openapi/bundled.json b/x-pack/plugins/cases/docs/openapi/bundled.json index 80cdefd30e957..54a9c31d34312 100644 --- a/x-pack/plugins/cases/docs/openapi/bundled.json +++ b/x-pack/plugins/cases/docs/openapi/bundled.json @@ -1206,8 +1206,11 @@ "$ref": "#/components/schemas/case_response_properties" }, "examples": { - "getCaseResponse": { + "getDefaultCaseResponse": { "$ref": "#/components/examples/get_case_response" + }, + "getDefaultObservabilityCaseReponse": { + "$ref": "#/components/examples/get_case_observability_response" } } } @@ -3078,6 +3081,9 @@ "examples": { "getCaseResponse": { "$ref": "#/components/examples/get_case_response" + }, + "getObservabilityCaseReponse": { + "$ref": "#/components/examples/get_case_observability_response" } } } @@ -4614,13 +4620,16 @@ ], "properties": { "alertId": { - "type": "string", - "example": "6b24c4dc44bc720cfc92797f3d61fff952f2b2627db1fb4f8cc49f4530c4ff42" + "type": "array", + "items": { + "type": "string", + "example": "a6e12ac4-7bce-457b-84f6-d7ce8deb8446" + } }, "created_at": { "type": "string", "format": "date-time", - "example": "2022-03-24T02:31:03.210Z" + "example": "2023-11-06T19:29:38.424Z" }, "created_by": { "type": "object", @@ -4656,8 +4665,11 @@ "example": "73362370-ab1a-11ec-985f-97e55adae8b9" }, "index": { - "type": "string", - "example": ".internal.alerts-security.alerts-default-000001" + "type": "array", + "items": { + "type": "string", + "example": ".internal.alerts-security.alerts-default-000001" + } }, "owner": { "$ref": "#/components/schemas/owners" @@ -4723,10 +4735,11 @@ "updated_at": { "type": "string", "format": "date-time", - "example": null + "nullable": true }, "updated_by": { "type": "object", + "nullable": true, "required": [ "email", "full_name", @@ -6971,6 +6984,7 @@ "syncAlerts": true }, "owner": "cases", + "category": null, "customFields": [ { "type": "text", @@ -7017,6 +7031,104 @@ "external_service": null } }, + "get_case_observability_response": { + "summary": "Retrieves information about an Observability case including its alerts and comments.", + "value": { + "description": "An Observability case description.", + "owner": "observability", + "settings": { + "syncAlerts": false + }, + "tags": [ + "observability", + "tag 1" + ], + "title": "Observability case title 1", + "category": null, + "customFields": [], + "assignees": [ + { + "uid": "u_0wpfV1MqYDaXzLtRVY-gLMrddKDEmfz51Fszhj7hWC8_0" + } + ], + "connector": { + "id": "none", + "type": ".none", + "fields": null, + "name": "none" + }, + "severity": "low", + "status": "in-progress", + "duration": null, + "closed_at": null, + "closed_by": null, + "created_at": "2023-11-06T19:29:04.086Z", + "created_by": { + "username": "elastic", + "full_name": null, + "email": null + }, + "updated_at": "2023-11-06T19:47:55.662Z", + "updated_by": { + "username": "elastic", + "full_name": null, + "email": null, + "profile_uid": "u_mGBROF_q5bmFCATbLXAcCwKa0k8JvONAwSruelyKA5E_0" + }, + "external_service": null, + "id": "c3ff7550-def1-4e90-b6bc-c9969a4a09b1", + "version": "WzI0NywyXQ==", + "totalComment": 1, + "totalAlerts": 1, + "comments": [ + { + "alertId": [ + "a6e12ac4-7bce-457b-84f6-d7ce8deb8446" + ], + "index": [ + ".internal.alerts-observability.logs.alerts-default-000001" + ], + "type": "alert", + "rule": { + "id": "03e4eb87-62ca-4e5d-9570-3d7625e9669d", + "name": "Observability rule" + }, + "owner": "observability", + "created_at": "2023-11-06T19:29:38.424Z", + "created_by": { + "email": null, + "full_name": null, + "username": "elastic", + "profile_uid": "u_mGBROF_q5bmFCATbLXAcCwKa0k8JvONAwSruelyKA5E_0" + }, + "pushed_at": null, + "pushed_by": null, + "updated_at": null, + "updated_by": null, + "id": "59d438d0-79a9-4864-8d4b-e63adacebf6e", + "version": "WzY3LDJd" + }, + { + "comment": "The first comment.", + "type": "user", + "owner": "observability", + "created_at": "2023-11-06T19:29:57.812Z", + "created_by": { + "email": null, + "full_name": null, + "username": "elastic", + "profile_uid": "u_mGBROF_q5bmFCATbLXAcCwKa0k8JvONAwSruelyKA5E_0" + }, + "pushed_at": null, + "pushed_by": null, + "updated_at": null, + "updated_by": null, + "id": "d99342d3-3aa3-4b80-90ec-a702607604f5", + "version": "WzcyLDJd" + } + ] + } + }, "get_case_alerts_response": { "summary": "Retrieves all alerts attached to a case", "value": [ diff --git a/x-pack/plugins/cases/docs/openapi/bundled.yaml b/x-pack/plugins/cases/docs/openapi/bundled.yaml index ec5c1db337f29..8347d7d85741b 100644 --- a/x-pack/plugins/cases/docs/openapi/bundled.yaml +++ b/x-pack/plugins/cases/docs/openapi/bundled.yaml @@ -811,8 +811,10 @@ paths: schema: $ref: '#/components/schemas/case_response_properties' examples: - getCaseResponse: + getDefaultCaseResponse: $ref: '#/components/examples/get_case_response' + getDefaultObservabilityCaseReponse: + $ref: '#/components/examples/get_case_observability_response' '401': description: Authorization information is missing or invalid. content: @@ -2017,6 +2019,8 @@ paths: examples: getCaseResponse: $ref: '#/components/examples/get_case_response' + getObservabilityCaseReponse: + $ref: '#/components/examples/get_case_observability_response' '401': description: Authorization information is missing or invalid. content: @@ -3068,12 +3072,14 @@ components: - type properties: alertId: - type: string - example: 6b24c4dc44bc720cfc92797f3d61fff952f2b2627db1fb4f8cc49f4530c4ff42 + type: array + items: + type: string + example: a6e12ac4-7bce-457b-84f6-d7ce8deb8446 created_at: type: string format: date-time - example: '2022-03-24T02:31:03.210Z' + example: '2023-11-06T19:29:38.424Z' created_by: type: object required: @@ -3100,8 +3106,10 @@ components: type: string example: 73362370-ab1a-11ec-985f-97e55adae8b9 index: - type: string - example: .internal.alerts-security.alerts-default-000001 + type: array + items: + type: string + example: .internal.alerts-security.alerts-default-000001 owner: $ref: '#/components/schemas/owners' pushed_at: @@ -3151,9 +3159,10 @@ components: updated_at: type: string format: date-time - example: null + nullable: true updated_by: type: object + nullable: true required: - email - full_name @@ -4769,6 +4778,7 @@ components: settings: syncAlerts: true owner: cases + category: null customFields: - type: text key: d312efda-ec2b-42ec-9e2c-84981795c581 @@ -4802,6 +4812,84 @@ components: type: .none fields: null external_service: null + get_case_observability_response: + summary: Retrieves information about an Observability case including its alerts and comments. + value: + description: An Observability case description. + owner: observability + settings: + syncAlerts: false + tags: + - observability + - tag 1 + title: Observability case title 1 + category: null + customFields: [] + assignees: + - uid: u_0wpfV1MqYDaXzLtRVY-gLMrddKDEmfz51Fszhj7hWC8_0 + connector: + id: none + type: .none + fields: null + name: none + severity: low + status: in-progress + duration: null + closed_at: null + closed_by: null + created_at: '2023-11-06T19:29:04.086Z' + created_by: + username: elastic + full_name: null + email: null + updated_at: '2023-11-06T19:47:55.662Z' + updated_by: + username: elastic + full_name: null + email: null + profile_uid: u_mGBROF_q5bmFCATbLXAcCwKa0k8JvONAwSruelyKA5E_0 + external_service: null + id: c3ff7550-def1-4e90-b6bc-c9969a4a09b1 + version: WzI0NywyXQ== + totalComment: 1 + totalAlerts: 1 + comments: + - alertId: + - a6e12ac4-7bce-457b-84f6-d7ce8deb8446 + index: + - .internal.alerts-observability.logs.alerts-default-000001 + type: alert + rule: + id: 03e4eb87-62ca-4e5d-9570-3d7625e9669d + name: Observability rule + owner: observability + created_at: '2023-11-06T19:29:38.424Z' + created_by: + email: null + full_name: null + username: elastic + profile_uid: u_mGBROF_q5bmFCATbLXAcCwKa0k8JvONAwSruelyKA5E_0 + pushed_at: null + pushed_by: null + updated_at: null + updated_by: null + id: 59d438d0-79a9-4864-8d4b-e63adacebf6e + version: WzY3LDJd + - comment: The first comment. + type: user + owner: observability + created_at: '2023-11-06T19:29:57.812Z' + created_by: + email: null + full_name: null + username: elastic + profile_uid: u_mGBROF_q5bmFCATbLXAcCwKa0k8JvONAwSruelyKA5E_0 + pushed_at: null + pushed_by: null + updated_at: null + updated_by: null + id: d99342d3-3aa3-4b80-90ec-a702607604f5 + version: WzcyLDJd get_case_alerts_response: summary: Retrieves all alerts attached to a case value: diff --git a/x-pack/plugins/cases/docs/openapi/components/examples/get_case_observability_response.yaml b/x-pack/plugins/cases/docs/openapi/components/examples/get_case_observability_response.yaml new file mode 100644 index 0000000000000..49b9aa692a335 --- /dev/null +++ b/x-pack/plugins/cases/docs/openapi/components/examples/get_case_observability_response.yaml @@ -0,0 +1,97 @@ +summary: Retrieves information about an Observability case including its alerts and comments. +value: + { + "description": "An Observability case description.", + "owner": "observability", + "settings": { + "syncAlerts": false + }, + "tags": [ + "observability", + "tag 1" + ], + "title": "Observability case title 1", + "category": null, + "customFields": [], + "assignees": [ + { + "uid": "u_0wpfV1MqYDaXzLtRVY-gLMrddKDEmfz51Fszhj7hWC8_0" + } + ], + "connector": { + "id": "none", + "type": ".none", + "fields": null, + "name": "none" + }, + "severity": "low", + "status": "in-progress", + "duration": null, + "closed_at": null, + "closed_by": null, + "created_at": "2023-11-06T19:29:04.086Z", + "created_by": { + "username": "elastic", + "full_name": null, + "email": null + }, + "updated_at": "2023-11-06T19:47:55.662Z", + "updated_by": { + "username": "elastic", + "full_name": null, + "email": null, + "profile_uid": "u_mGBROF_q5bmFCATbLXAcCwKa0k8JvONAwSruelyKA5E_0" + }, + "external_service": null, + "id": "c3ff7550-def1-4e90-b6bc-c9969a4a09b1", + "version": "WzI0NywyXQ==", + "totalComment": 1, + "totalAlerts": 1, + "comments": [ + { + "alertId": [ + "a6e12ac4-7bce-457b-84f6-d7ce8deb8446" + ], + "index": [ + ".internal.alerts-observability.logs.alerts-default-000001" + ], + "type": "alert", + "rule": { + "id": "03e4eb87-62ca-4e5d-9570-3d7625e9669d", + "name": "Observability rule" + }, + "owner": "observability", + "created_at": "2023-11-06T19:29:38.424Z", + "created_by": { + "email": null, + "full_name": null, + "username": "elastic", + "profile_uid": "u_mGBROF_q5bmFCATbLXAcCwKa0k8JvONAwSruelyKA5E_0" + }, + "pushed_at": null, + "pushed_by": null, + "updated_at": null, + "updated_by": null, + "id": "59d438d0-79a9-4864-8d4b-e63adacebf6e", + "version": "WzY3LDJd" + }, + { + "comment": "The first comment.", + "type": "user", + "owner": "observability", + "created_at": "2023-11-06T19:29:57.812Z", + "created_by": { + "email": null, + "full_name": null, + "username": "elastic", + "profile_uid": "u_mGBROF_q5bmFCATbLXAcCwKa0k8JvONAwSruelyKA5E_0" + }, + "pushed_at": null, + "pushed_by": null, + "updated_at": null, + "updated_by": null, + "id": "d99342d3-3aa3-4b80-90ec-a702607604f5", + "version": "WzcyLDJd" + } + ] +} \ No newline at end of file diff --git a/x-pack/plugins/cases/docs/openapi/components/examples/get_case_response.yaml b/x-pack/plugins/cases/docs/openapi/components/examples/get_case_response.yaml index d4fc3db97a169..50dabd2dc8a9b 100644 --- a/x-pack/plugins/cases/docs/openapi/components/examples/get_case_response.yaml +++ b/x-pack/plugins/cases/docs/openapi/components/examples/get_case_response.yaml @@ -27,6 +27,7 @@ value: "tags":["tag 1"], "settings":{"syncAlerts":true}, "owner":"cases", + "category":null, "customFields": [ { "type": "text", diff --git a/x-pack/plugins/cases/docs/openapi/components/schemas/alert_comment_response_properties.yaml b/x-pack/plugins/cases/docs/openapi/components/schemas/alert_comment_response_properties.yaml index aa39aad1381a0..443d9dcc55523 100644 --- a/x-pack/plugins/cases/docs/openapi/components/schemas/alert_comment_response_properties.yaml +++ b/x-pack/plugins/cases/docs/openapi/components/schemas/alert_comment_response_properties.yaml @@ -4,12 +4,14 @@ required: - type properties: alertId: - type: string - example: 6b24c4dc44bc720cfc92797f3d61fff952f2b2627db1fb4f8cc49f4530c4ff42 + type: array + items: + type: string + example: a6e12ac4-7bce-457b-84f6-d7ce8deb8446 created_at: type: string format: date-time - example: 2022-03-24T02:31:03.210Z + example: 2023-11-06T19:29:38.424Z created_by: type: object required: @@ -22,8 +24,10 @@ properties: type: string example: 73362370-ab1a-11ec-985f-97e55adae8b9 index: - type: string - example: .internal.alerts-security.alerts-default-000001 + type: array + items: + type: string + example: .internal.alerts-security.alerts-default-000001 owner: $ref: 'owners.yaml' pushed_at: @@ -52,9 +56,10 @@ properties: updated_at: type: string format: date-time - example: null + nullable: true updated_by: type: object + nullable: true required: - email - full_name diff --git a/x-pack/plugins/cases/docs/openapi/paths/api@cases@{caseid}.yaml b/x-pack/plugins/cases/docs/openapi/paths/api@cases@{caseid}.yaml index 9629049c9b342..c5b52a52b741f 100644 --- a/x-pack/plugins/cases/docs/openapi/paths/api@cases@{caseid}.yaml +++ b/x-pack/plugins/cases/docs/openapi/paths/api@cases@{caseid}.yaml @@ -18,8 +18,10 @@ get: schema: $ref: '../components/schemas/case_response_properties.yaml' examples: - getCaseResponse: + getDefaultCaseResponse: $ref: '../components/examples/get_case_response.yaml' + getDefaultObservabilityCaseReponse: + $ref: '../components/examples/get_case_observability_response.yaml' '401': description: Authorization information is missing or invalid. content: diff --git a/x-pack/plugins/cases/docs/openapi/paths/s@{spaceid}@api@cases@{caseid}.yaml b/x-pack/plugins/cases/docs/openapi/paths/s@{spaceid}@api@cases@{caseid}.yaml index 32e3434f15add..aecd3f6394bb7 100644 --- a/x-pack/plugins/cases/docs/openapi/paths/s@{spaceid}@api@cases@{caseid}.yaml +++ b/x-pack/plugins/cases/docs/openapi/paths/s@{spaceid}@api@cases@{caseid}.yaml @@ -21,6 +21,8 @@ get: examples: getCaseResponse: $ref: '../components/examples/get_case_response.yaml' + getObservabilityCaseReponse: + $ref: '../components/examples/get_case_observability_response.yaml' '401': description: Authorization information is missing or invalid. content: diff --git a/x-pack/plugins/cases/public/common/mock/test_providers.tsx b/x-pack/plugins/cases/public/common/mock/test_providers.tsx index 7dfed5d7188de..846ae8172b327 100644 --- a/x-pack/plugins/cases/public/common/mock/test_providers.tsx +++ b/x-pack/plugins/cases/public/common/mock/test_providers.tsx @@ -11,6 +11,7 @@ import React from 'react'; import { MemoryRouter } from 'react-router-dom'; import { ThemeProvider } from 'styled-components'; +import { render as reactRender } from '@testing-library/react'; import type { RenderOptions, RenderResult } from '@testing-library/react'; import type { ILicense } from '@kbn/licensing-plugin/public'; import type { ScopedFilesClient } from '@kbn/files-plugin/public'; @@ -20,7 +21,6 @@ import { I18nProvider } from '@kbn/i18n-react'; import { createMockFilesClient } from '@kbn/shared-ux-file-mocks'; import { QueryClient, QueryClientProvider } from '@tanstack/react-query'; -import { render as reactRender } from '@testing-library/react'; import { KibanaContextProvider } from '@kbn/kibana-react-plugin/public'; import { FilesContext } from '@kbn/shared-ux-file-context'; diff --git a/x-pack/plugins/cases/public/common/use_cases_toast.test.tsx b/x-pack/plugins/cases/public/common/use_cases_toast.test.tsx index d6597e31362e7..53fe9118a6aa0 100644 --- a/x-pack/plugins/cases/public/common/use_cases_toast.test.tsx +++ b/x-pack/plugins/cases/public/common/use_cases_toast.test.tsx @@ -14,7 +14,7 @@ import { alertComment, basicComment, mockCase } from '../containers/mock'; import React from 'react'; import userEvent from '@testing-library/user-event'; import type { SupportedCaseAttachment } from '../types'; -import { getByTestId } from '@testing-library/dom'; +import { getByTestId } from '@testing-library/react'; import { OWNER_INFO } from '../../common/constants'; jest.mock('./lib/kibana'); diff --git a/x-pack/plugins/cases/public/components/all_cases/selector_modal/use_cases_add_to_existing_case_modal.test.tsx b/x-pack/plugins/cases/public/components/all_cases/selector_modal/use_cases_add_to_existing_case_modal.test.tsx index 2cfaacc8383ca..a80e1935d1add 100644 --- a/x-pack/plugins/cases/public/components/all_cases/selector_modal/use_cases_add_to_existing_case_modal.test.tsx +++ b/x-pack/plugins/cases/public/components/all_cases/selector_modal/use_cases_add_to_existing_case_modal.test.tsx @@ -5,7 +5,7 @@ * 2.0. */ -import { waitFor } from '@testing-library/dom'; +import { waitFor } from '@testing-library/react'; import { act, renderHook } from '@testing-library/react-hooks'; import userEvent from '@testing-library/user-event'; import React from 'react'; diff --git a/x-pack/plugins/cases/public/components/all_cases/severity_filter.test.tsx b/x-pack/plugins/cases/public/components/all_cases/severity_filter.test.tsx index 30d5c75e63589..26169e16c5bed 100644 --- a/x-pack/plugins/cases/public/components/all_cases/severity_filter.test.tsx +++ b/x-pack/plugins/cases/public/components/all_cases/severity_filter.test.tsx @@ -10,7 +10,7 @@ import React from 'react'; import type { AppMockRenderer } from '../../common/mock'; import { createAppMockRenderer } from '../../common/mock'; import userEvent from '@testing-library/user-event'; -import { waitFor } from '@testing-library/dom'; +import { waitFor } from '@testing-library/react'; import { waitForEuiPopoverOpen } from '@elastic/eui/lib/test/rtl'; import { SeverityFilter } from './severity_filter'; diff --git a/x-pack/plugins/cases/public/components/all_cases/use_actions.test.tsx b/x-pack/plugins/cases/public/components/all_cases/use_actions.test.tsx index 0efc7a5862893..ecc9233fc327c 100644 --- a/x-pack/plugins/cases/public/components/all_cases/use_actions.test.tsx +++ b/x-pack/plugins/cases/public/components/all_cases/use_actions.test.tsx @@ -6,7 +6,7 @@ */ import userEvent from '@testing-library/user-event'; -import { waitFor } from '@testing-library/dom'; +import { waitFor } from '@testing-library/react'; import { renderHook } from '@testing-library/react-hooks/dom'; import { useActions } from './use_actions'; diff --git a/x-pack/plugins/cases/public/components/case_action_bar/actions.test.tsx b/x-pack/plugins/cases/public/components/case_action_bar/actions.test.tsx index c79e88ce350ab..ef97a5f8d854d 100644 --- a/x-pack/plugins/cases/public/components/case_action_bar/actions.test.tsx +++ b/x-pack/plugins/cases/public/components/case_action_bar/actions.test.tsx @@ -13,7 +13,7 @@ import { basicCase, basicPush } from '../../containers/mock'; import { Actions } from './actions'; import * as i18n from '../case_view/translations'; import * as api from '../../containers/api'; -import { waitFor } from '@testing-library/dom'; +import { waitFor } from '@testing-library/react'; jest.mock('../../containers/api'); diff --git a/x-pack/plugins/cases/public/components/case_view/components/case_view_alerts.test.tsx b/x-pack/plugins/cases/public/components/case_view/components/case_view_alerts.test.tsx index cba9169590839..b85dbe7564cf9 100644 --- a/x-pack/plugins/cases/public/components/case_view/components/case_view_alerts.test.tsx +++ b/x-pack/plugins/cases/public/components/case_view/components/case_view_alerts.test.tsx @@ -6,7 +6,7 @@ */ import React from 'react'; -import { waitFor } from '@testing-library/dom'; +import { waitFor } from '@testing-library/react'; import { OBSERVABILITY_OWNER } from '../../../../common/constants'; import { alertCommentWithIndices, basicCase } from '../../../containers/mock'; import type { AppMockRenderer } from '../../../common/mock'; diff --git a/x-pack/plugins/cases/public/components/case_view/index.test.tsx b/x-pack/plugins/cases/public/components/case_view/index.test.tsx index 07b58820b52b7..13524989bc7b8 100644 --- a/x-pack/plugins/cases/public/components/case_view/index.test.tsx +++ b/x-pack/plugins/cases/public/components/case_view/index.test.tsx @@ -30,7 +30,7 @@ import { useGetSupportedActionConnectors } from '../../containers/configure/use_ import type { AppMockRenderer } from '../../common/mock'; import { createAppMockRenderer } from '../../common/mock'; import CaseView from '.'; -import { waitFor } from '@testing-library/dom'; +import { waitFor } from '@testing-library/react'; import { useGetTags } from '../../containers/use_get_tags'; import { casesQueriesKeys } from '../../containers/constants'; import { diff --git a/x-pack/plugins/cases/public/components/create/form.test.tsx b/x-pack/plugins/cases/public/components/create/form.test.tsx index e7bd2fc754f34..05e7788624800 100644 --- a/x-pack/plugins/cases/public/components/create/form.test.tsx +++ b/x-pack/plugins/cases/public/components/create/form.test.tsx @@ -7,8 +7,7 @@ import React from 'react'; import { mount } from 'enzyme'; -import { act, render, within, fireEvent } from '@testing-library/react'; -import { waitFor } from '@testing-library/dom'; +import { act, render, within, fireEvent, waitFor } from '@testing-library/react'; import { licensingMock } from '@kbn/licensing-plugin/public/mocks'; import { NONE_CONNECTOR_ID } from '../../../common/constants'; diff --git a/x-pack/plugins/cases/public/components/create/severity.test.tsx b/x-pack/plugins/cases/public/components/create/severity.test.tsx index 328b9b4cd5e00..bf81dfc357fc7 100644 --- a/x-pack/plugins/cases/public/components/create/severity.test.tsx +++ b/x-pack/plugins/cases/public/components/create/severity.test.tsx @@ -15,7 +15,7 @@ import { Severity } from './severity'; import type { FormProps } from './schema'; import { schema } from './schema'; import userEvent from '@testing-library/user-event'; -import { waitFor } from '@testing-library/dom'; +import { waitFor } from '@testing-library/react'; import { waitForEuiPopoverOpen } from '@elastic/eui/lib/test/rtl'; let globalForm: FormHook; diff --git a/x-pack/plugins/cases/public/components/custom_fields/index.test.tsx b/x-pack/plugins/cases/public/components/custom_fields/index.test.tsx index d81e31ba69d6d..7864361063b31 100644 --- a/x-pack/plugins/cases/public/components/custom_fields/index.test.tsx +++ b/x-pack/plugins/cases/public/components/custom_fields/index.test.tsx @@ -7,7 +7,7 @@ import React from 'react'; import userEvent from '@testing-library/user-event'; -import { screen, waitFor } from '@testing-library/dom'; +import { screen, waitFor } from '@testing-library/react'; import type { AppMockRenderer } from '../../common/mock'; import { createAppMockRenderer } from '../../common/mock'; diff --git a/x-pack/plugins/cases/public/components/experimental_badge/experimental_badge.test.tsx b/x-pack/plugins/cases/public/components/experimental_badge/experimental_badge.test.tsx index a13aea90e8e6e..38b5960898cf0 100644 --- a/x-pack/plugins/cases/public/components/experimental_badge/experimental_badge.test.tsx +++ b/x-pack/plugins/cases/public/components/experimental_badge/experimental_badge.test.tsx @@ -6,7 +6,7 @@ */ import React from 'react'; -import { screen } from '@testing-library/dom'; +import { screen } from '@testing-library/react'; import type { AppMockRenderer } from '../../common/mock'; import { createAppMockRenderer } from '../../common/mock'; diff --git a/x-pack/plugins/cases/public/components/visualizations/actions/add_to_existing_case.test.tsx b/x-pack/plugins/cases/public/components/visualizations/actions/add_to_existing_case.test.tsx index 9c911e5aa89b4..a32ece05eac74 100644 --- a/x-pack/plugins/cases/public/components/visualizations/actions/add_to_existing_case.test.tsx +++ b/x-pack/plugins/cases/public/components/visualizations/actions/add_to_existing_case.test.tsx @@ -24,7 +24,7 @@ import { mockTimeRange, } from './mocks'; import { useKibana } from '../../../common/lib/kibana'; -import { waitFor } from '@testing-library/dom'; +import { waitFor } from '@testing-library/react'; import { canUseCases } from '../../../client/helpers/can_use_cases'; import { getCaseOwnerByAppId } from '../../../../common/utils/owner'; diff --git a/x-pack/plugins/cases/public/components/visualizations/actions/add_to_new_case.test.tsx b/x-pack/plugins/cases/public/components/visualizations/actions/add_to_new_case.test.tsx index f55f95cbfb0ec..3549ca3301d18 100644 --- a/x-pack/plugins/cases/public/components/visualizations/actions/add_to_new_case.test.tsx +++ b/x-pack/plugins/cases/public/components/visualizations/actions/add_to_new_case.test.tsx @@ -8,7 +8,7 @@ import { LENS_EMBEDDABLE_TYPE, type Embeddable as LensEmbeddable } from '@kbn/lens-plugin/public'; import { ErrorEmbeddable } from '@kbn/embeddable-plugin/public'; import type { Action } from '@kbn/ui-actions-plugin/public'; -import { waitFor } from '@testing-library/dom'; +import { waitFor } from '@testing-library/react'; import { createAddToNewCaseLensAction } from './add_to_new_case'; import type { ActionContext } from './types'; diff --git a/x-pack/plugins/cases/public/containers/configure/use_get_case_configuration.test.tsx b/x-pack/plugins/cases/public/containers/configure/use_get_case_configuration.test.tsx index 1cb8685e26cbf..d625e247cb572 100644 --- a/x-pack/plugins/cases/public/containers/configure/use_get_case_configuration.test.tsx +++ b/x-pack/plugins/cases/public/containers/configure/use_get_case_configuration.test.tsx @@ -8,7 +8,7 @@ import { renderHook } from '@testing-library/react-hooks'; import { useGetCaseConfiguration } from './use_get_case_configuration'; import * as api from './api'; -import { waitFor } from '@testing-library/dom'; +import { waitFor } from '@testing-library/react'; import { useToasts } from '../../common/lib/kibana'; import type { AppMockRenderer } from '../../common/mock'; import { createAppMockRenderer } from '../../common/mock'; diff --git a/x-pack/plugins/cases/public/containers/use_get_case.test.tsx b/x-pack/plugins/cases/public/containers/use_get_case.test.tsx index 0514acf4a71ea..2b5082a9e22a5 100644 --- a/x-pack/plugins/cases/public/containers/use_get_case.test.tsx +++ b/x-pack/plugins/cases/public/containers/use_get_case.test.tsx @@ -8,7 +8,7 @@ import { renderHook } from '@testing-library/react-hooks'; import { useGetCase } from './use_get_case'; import * as api from './api'; -import { waitFor } from '@testing-library/dom'; +import { waitFor } from '@testing-library/react'; import React from 'react'; import { QueryClient, QueryClientProvider } from '@tanstack/react-query'; import { useToasts } from '../common/lib/kibana'; diff --git a/x-pack/plugins/cases/public/containers/use_get_feature_ids.test.tsx b/x-pack/plugins/cases/public/containers/use_get_feature_ids.test.tsx index fdec17c215fda..298abb5d133e7 100644 --- a/x-pack/plugins/cases/public/containers/use_get_feature_ids.test.tsx +++ b/x-pack/plugins/cases/public/containers/use_get_feature_ids.test.tsx @@ -6,7 +6,7 @@ */ import { renderHook } from '@testing-library/react-hooks'; -import { waitFor } from '@testing-library/dom'; +import { waitFor } from '@testing-library/react'; import { useToasts } from '../common/lib/kibana'; import type { AppMockRenderer } from '../common/mock'; import { createAppMockRenderer } from '../common/mock'; diff --git a/x-pack/plugins/cases/server/services/notifications/templates/assignees/renderer.test.ts b/x-pack/plugins/cases/server/services/notifications/templates/assignees/renderer.test.ts index ecd0bc08393bb..fb6509aeceeb4 100644 --- a/x-pack/plugins/cases/server/services/notifications/templates/assignees/renderer.test.ts +++ b/x-pack/plugins/cases/server/services/notifications/templates/assignees/renderer.test.ts @@ -6,7 +6,7 @@ */ import { mockCases } from '../../../../mocks'; -import { getByText } from '@testing-library/dom'; +import { getByText } from '@testing-library/react'; import { assigneesTemplateRenderer } from './renderer'; import type { CaseSavedObjectTransformed } from '../../../../common/types/case'; diff --git a/x-pack/plugins/cases/server/services/notifications/templates/assignees/template.test.ts b/x-pack/plugins/cases/server/services/notifications/templates/assignees/template.test.ts index b888cd6017b24..79589f4e58bef 100644 --- a/x-pack/plugins/cases/server/services/notifications/templates/assignees/template.test.ts +++ b/x-pack/plugins/cases/server/services/notifications/templates/assignees/template.test.ts @@ -6,7 +6,7 @@ */ import { mockCases } from '../../../../mocks'; -import { getByText } from '@testing-library/dom'; +import { getByText } from '@testing-library/react'; import { assigneesTemplateRenderer } from './renderer'; import type { CaseSavedObjectTransformed } from '../../../../common/types/case'; diff --git a/x-pack/plugins/cloud_security_posture/public/pages/compliance_dashboard/dashboard_sections/summary_section.test.tsx b/x-pack/plugins/cloud_security_posture/public/pages/compliance_dashboard/dashboard_sections/summary_section.test.tsx index 0545d4f3bb429..04c8382529593 100644 --- a/x-pack/plugins/cloud_security_posture/public/pages/compliance_dashboard/dashboard_sections/summary_section.test.tsx +++ b/x-pack/plugins/cloud_security_posture/public/pages/compliance_dashboard/dashboard_sections/summary_section.test.tsx @@ -6,13 +6,12 @@ */ import React from 'react'; -import { render } from '@testing-library/react'; +import { render, screen } from '@testing-library/react'; import { expectIdsInDoc } from '../../../test/utils'; import { DASHBOARD_COUNTER_CARDS } from '../test_subjects'; import { SummarySection } from './summary_section'; import { mockDashboardData } from '../mock'; import { TestProvider } from '../../../test/test_provider'; -import { screen } from '@testing-library/react'; import { KSPM_POLICY_TEMPLATE } from '../../../../common/constants'; describe('', () => { diff --git a/x-pack/plugins/enterprise_search/public/applications/app_search/components/role_mappings/engine_assignment_selector.test.tsx b/x-pack/plugins/enterprise_search/public/applications/app_search/components/role_mappings/engine_assignment_selector.test.tsx index a8f8b2af988f2..74ca02e1d91db 100644 --- a/x-pack/plugins/enterprise_search/public/applications/app_search/components/role_mappings/engine_assignment_selector.test.tsx +++ b/x-pack/plugins/enterprise_search/public/applications/app_search/components/role_mappings/engine_assignment_selector.test.tsx @@ -13,7 +13,7 @@ import { engines } from '../../__mocks__/engines.mock'; import React from 'react'; -import { waitFor } from '@testing-library/dom'; +import { waitFor } from '@testing-library/react'; import { shallow } from 'enzyme'; import { EuiComboBox, EuiComboBoxOptionOption, EuiRadioGroup } from '@elastic/eui'; diff --git a/x-pack/plugins/enterprise_search/public/applications/workplace_search/views/role_mappings/group_assignment_selector.test.tsx b/x-pack/plugins/enterprise_search/public/applications/workplace_search/views/role_mappings/group_assignment_selector.test.tsx index 9312b1b6bbdb2..1cea94e434de1 100644 --- a/x-pack/plugins/enterprise_search/public/applications/workplace_search/views/role_mappings/group_assignment_selector.test.tsx +++ b/x-pack/plugins/enterprise_search/public/applications/workplace_search/views/role_mappings/group_assignment_selector.test.tsx @@ -11,7 +11,7 @@ import { setMockActions, setMockValues } from '../../../__mocks__/kea_logic'; import React from 'react'; -import { waitFor } from '@testing-library/dom'; +import { waitFor } from '@testing-library/react'; import { shallow } from 'enzyme'; import { EuiComboBox, EuiComboBoxOptionOption, EuiRadioGroup } from '@elastic/eui'; diff --git a/x-pack/plugins/exploratory_view/kibana.jsonc b/x-pack/plugins/exploratory_view/kibana.jsonc index e541ad7858650..b8041aaec89df 100644 --- a/x-pack/plugins/exploratory_view/kibana.jsonc +++ b/x-pack/plugins/exploratory_view/kibana.jsonc @@ -1,7 +1,7 @@ { "type": "plugin", "id": "@kbn/exploratory-view-plugin", - "owner": "@elastic/uptime", + "owner": "@elastic/obs-ux-infra_services-team", "plugin": { "id": "exploratoryView", "server": false, diff --git a/x-pack/plugins/exploratory_view/public/components/shared/exploratory_view/components/action_menu/action_menu.test.tsx b/x-pack/plugins/exploratory_view/public/components/shared/exploratory_view/components/action_menu/action_menu.test.tsx index c72899d8041c7..4e81ca840199f 100644 --- a/x-pack/plugins/exploratory_view/public/components/shared/exploratory_view/components/action_menu/action_menu.test.tsx +++ b/x-pack/plugins/exploratory_view/public/components/shared/exploratory_view/components/action_menu/action_menu.test.tsx @@ -6,7 +6,7 @@ */ import { render } from '../../rtl_helpers'; -import { fireEvent, screen } from '@testing-library/dom'; +import { fireEvent, screen } from '@testing-library/react'; import React from 'react'; import { sampleAttribute } from '../../configurations/test_data/sample_attribute'; import * as pluginHook from '../../../../../hooks/use_plugin_context'; diff --git a/x-pack/plugins/exploratory_view/public/components/shared/exploratory_view/exploratory_view.test.tsx b/x-pack/plugins/exploratory_view/public/components/shared/exploratory_view/exploratory_view.test.tsx index 443a6eb846cd8..7b4e0cb5cc57f 100644 --- a/x-pack/plugins/exploratory_view/public/components/shared/exploratory_view/exploratory_view.test.tsx +++ b/x-pack/plugins/exploratory_view/public/components/shared/exploratory_view/exploratory_view.test.tsx @@ -6,7 +6,7 @@ */ import React from 'react'; -import { screen } from '@testing-library/dom'; +import { screen } from '@testing-library/react'; import { render, mockAppDataView } from './rtl_helpers'; import { ExploratoryView } from './exploratory_view'; import * as obsvDataViews from '../../../utils/observability_data_views/observability_data_views'; diff --git a/x-pack/plugins/exploratory_view/public/components/shared/exploratory_view/header/add_to_case_action.test.tsx b/x-pack/plugins/exploratory_view/public/components/shared/exploratory_view/header/add_to_case_action.test.tsx index a4d8a88507e82..ffccfdf6db3f2 100644 --- a/x-pack/plugins/exploratory_view/public/components/shared/exploratory_view/header/add_to_case_action.test.tsx +++ b/x-pack/plugins/exploratory_view/public/components/shared/exploratory_view/header/add_to_case_action.test.tsx @@ -7,7 +7,7 @@ import React from 'react'; import { render, forNearestButton } from '../rtl_helpers'; -import { fireEvent } from '@testing-library/dom'; +import { fireEvent } from '@testing-library/react'; import { AddToCaseAction } from './add_to_case_action'; import * as useCaseHook from '../hooks/use_add_to_case'; import * as datePicker from '../components/date_range_picker'; diff --git a/x-pack/plugins/exploratory_view/public/components/shared/exploratory_view/header/chart_creation_info.test.tsx b/x-pack/plugins/exploratory_view/public/components/shared/exploratory_view/header/chart_creation_info.test.tsx index 570362a63c33f..f8da480072ab3 100644 --- a/x-pack/plugins/exploratory_view/public/components/shared/exploratory_view/header/chart_creation_info.test.tsx +++ b/x-pack/plugins/exploratory_view/public/components/shared/exploratory_view/header/chart_creation_info.test.tsx @@ -6,7 +6,7 @@ */ import React from 'react'; -import { screen } from '@testing-library/dom'; +import { screen } from '@testing-library/react'; import { render } from '../rtl_helpers'; import { ChartCreationInfo } from './chart_creation_info'; diff --git a/x-pack/plugins/exploratory_view/public/components/shared/exploratory_view/hooks/use_add_to_case.test.tsx b/x-pack/plugins/exploratory_view/public/components/shared/exploratory_view/hooks/use_add_to_case.test.tsx index 9ab9d00d2bc82..3821c703e7cee 100644 --- a/x-pack/plugins/exploratory_view/public/components/shared/exploratory_view/hooks/use_add_to_case.test.tsx +++ b/x-pack/plugins/exploratory_view/public/components/shared/exploratory_view/hooks/use_add_to_case.test.tsx @@ -9,7 +9,7 @@ import { useAddToCase } from './use_add_to_case'; import React, { useEffect } from 'react'; import { render } from '../rtl_helpers'; import { EuiButton } from '@elastic/eui'; -import { fireEvent } from '@testing-library/dom'; +import { fireEvent } from '@testing-library/react'; import { act } from '@testing-library/react'; describe('useAddToCase', function () { diff --git a/x-pack/plugins/exploratory_view/public/components/shared/exploratory_view/views/add_series_button.test.tsx b/x-pack/plugins/exploratory_view/public/components/shared/exploratory_view/views/add_series_button.test.tsx index 978296a295efc..65f80245c2ceb 100644 --- a/x-pack/plugins/exploratory_view/public/components/shared/exploratory_view/views/add_series_button.test.tsx +++ b/x-pack/plugins/exploratory_view/public/components/shared/exploratory_view/views/add_series_button.test.tsx @@ -6,7 +6,7 @@ */ import React from 'react'; -import { screen, waitFor, fireEvent } from '@testing-library/dom'; +import { screen, waitFor, fireEvent } from '@testing-library/react'; import { render } from '../rtl_helpers'; import { AddSeriesButton } from './add_series_button'; import { DEFAULT_TIME, ReportTypes } from '../configurations/constants'; diff --git a/x-pack/plugins/exploratory_view/public/components/shared/exploratory_view/views/view_actions.test.tsx b/x-pack/plugins/exploratory_view/public/components/shared/exploratory_view/views/view_actions.test.tsx index df709c94abcde..ae2d2ce65d91c 100644 --- a/x-pack/plugins/exploratory_view/public/components/shared/exploratory_view/views/view_actions.test.tsx +++ b/x-pack/plugins/exploratory_view/public/components/shared/exploratory_view/views/view_actions.test.tsx @@ -6,7 +6,7 @@ */ import React from 'react'; -import { screen, waitFor, fireEvent } from '@testing-library/dom'; +import { screen, waitFor, fireEvent } from '@testing-library/react'; import { render } from '../rtl_helpers'; import * as hooks from '../hooks/use_series_storage'; import { ViewActions } from './view_actions'; diff --git a/x-pack/plugins/fleet/public/applications/fleet/sections/agents/agent_details_page/components/action_menu.test.tsx b/x-pack/plugins/fleet/public/applications/fleet/sections/agents/agent_details_page/components/action_menu.test.tsx index 2f05354b09a04..2d39700da5caa 100644 --- a/x-pack/plugins/fleet/public/applications/fleet/sections/agents/agent_details_page/components/action_menu.test.tsx +++ b/x-pack/plugins/fleet/public/applications/fleet/sections/agents/agent_details_page/components/action_menu.test.tsx @@ -6,7 +6,7 @@ */ import React from 'react'; -import { fireEvent } from '@testing-library/dom'; +import { fireEvent } from '@testing-library/react'; import { createFleetTestRendererMock } from '../../../../../../mock'; import type { Agent, AgentPolicy } from '../../../../types'; diff --git a/x-pack/plugins/fleet/public/applications/fleet/sections/agents/agent_list_page/components/agent_upgrade_status.test.tsx b/x-pack/plugins/fleet/public/applications/fleet/sections/agents/agent_list_page/components/agent_upgrade_status.test.tsx index 9937126213c91..dffa4bc665bdb 100644 --- a/x-pack/plugins/fleet/public/applications/fleet/sections/agents/agent_list_page/components/agent_upgrade_status.test.tsx +++ b/x-pack/plugins/fleet/public/applications/fleet/sections/agents/agent_list_page/components/agent_upgrade_status.test.tsx @@ -5,7 +5,7 @@ * 2.0. */ -import { fireEvent, waitFor } from '@testing-library/dom'; +import { fireEvent, waitFor } from '@testing-library/react'; import React from 'react'; import { createFleetTestRendererMock } from '../../../../../../mock'; diff --git a/x-pack/plugins/fleet/public/applications/fleet/sections/agents/agent_list_page/components/table_row_actions.test.tsx b/x-pack/plugins/fleet/public/applications/fleet/sections/agents/agent_list_page/components/table_row_actions.test.tsx index a2fed8d3ed613..4e8d25f313ea5 100644 --- a/x-pack/plugins/fleet/public/applications/fleet/sections/agents/agent_list_page/components/table_row_actions.test.tsx +++ b/x-pack/plugins/fleet/public/applications/fleet/sections/agents/agent_list_page/components/table_row_actions.test.tsx @@ -6,7 +6,7 @@ */ import React from 'react'; -import { fireEvent } from '@testing-library/dom'; +import { fireEvent } from '@testing-library/react'; import { createFleetTestRendererMock } from '../../../../../../mock'; import type { Agent, AgentPolicy } from '../../../../types'; diff --git a/x-pack/plugins/kubernetes_security/public/components/count_widget/index.test.tsx b/x-pack/plugins/kubernetes_security/public/components/count_widget/index.test.tsx index a0fbe2c90c690..d3230a33f203e 100644 --- a/x-pack/plugins/kubernetes_security/public/components/count_widget/index.test.tsx +++ b/x-pack/plugins/kubernetes_security/public/components/count_widget/index.test.tsx @@ -10,7 +10,7 @@ import { AppContextTestRender, createAppRootMockRenderer } from '../../test'; import { GlobalFilter } from '../../types'; import { CountWidget, LOADING_TEST_ID, TOOLTIP_TEST_ID, VALUE_TEST_ID } from '.'; import { useFetchCountWidgetData } from './hooks'; -import { fireEvent, waitFor } from '@testing-library/dom'; +import { fireEvent, waitFor } from '@testing-library/react'; const TITLE = 'Count Widget Title'; const GLOBAL_FILTER: GlobalFilter = { diff --git a/x-pack/plugins/lens/public/mocks/store_mocks.tsx b/x-pack/plugins/lens/public/mocks/store_mocks.tsx index cafb7796969c8..9a3d33afa1aa7 100644 --- a/x-pack/plugins/lens/public/mocks/store_mocks.tsx +++ b/x-pack/plugins/lens/public/mocks/store_mocks.tsx @@ -13,26 +13,14 @@ import { act } from 'react-dom/test-utils'; import { PreloadedState } from '@reduxjs/toolkit'; import { RenderOptions, render } from '@testing-library/react'; import { I18nProvider } from '@kbn/i18n-react'; -// imported to prevent a type error from testing library https://github.com/testing-library/react-testing-library/issues/587 -import * as ___ from '@testing-library/dom'; - import { LensAppServices } from '../app_plugin/types'; -import { - makeConfigureStore, - LensAppState, - LensState, - LensStoreDeps, - LensRootStore, -} from '../state_management'; +import { makeConfigureStore, LensAppState, LensState, LensStoreDeps } from '../state_management'; import { getResolvedDateRange } from '../utils'; import { DatasourceMap, VisualizationMap } from '../types'; import { mockVisualizationMap } from './visualization_mock'; import { mockDatasourceMap } from './datasource_mock'; import { makeDefaultServices } from './services_mock'; -// preventing a type error from testing library https://github.com/testing-library/react-testing-library/issues/587 -export const unusedFn = () => ___; - export const mockStoreDeps = (deps?: { lensServices?: LensAppServices; datasourceMap?: DatasourceMap; @@ -85,7 +73,8 @@ export const renderWithReduxStore = ( preloadedState: {}, storeDeps: mockStoreDeps(), } -): ReturnType & { store: LensRootStore } => { + // eslint-disable-next-line @typescript-eslint/no-explicit-any +): any => { const { store } = makeLensStore({ preloadedState, storeDeps }); const Wrapper: React.FC<{ diff --git a/x-pack/plugins/lists/public/exceptions/components/builder/entry_renderer.test.tsx b/x-pack/plugins/lists/public/exceptions/components/builder/entry_renderer.test.tsx index b73379acd1518..7edcf5b53f724 100644 --- a/x-pack/plugins/lists/public/exceptions/components/builder/entry_renderer.test.tsx +++ b/x-pack/plugins/lists/public/exceptions/components/builder/entry_renderer.test.tsx @@ -25,7 +25,7 @@ import { useFindListsBySize } from '@kbn/securitysolution-list-hooks'; import type { FieldSpec } from '@kbn/data-plugin/common'; import { fields, getField } from '@kbn/data-plugin/common/mocks'; import { unifiedSearchPluginMock } from '@kbn/unified-search-plugin/public/mocks'; -import { waitFor } from '@testing-library/dom'; +import { waitFor } from '@testing-library/react'; import { ReactWrapper, mount } from 'enzyme'; import { getFoundListsBySizeSchemaMock } from '../../../../common/schemas/response/found_lists_by_size_schema.mock'; diff --git a/x-pack/plugins/log_explorer/kibana.jsonc b/x-pack/plugins/log_explorer/kibana.jsonc index 76eb47e4a5915..71781ca9cada3 100644 --- a/x-pack/plugins/log_explorer/kibana.jsonc +++ b/x-pack/plugins/log_explorer/kibana.jsonc @@ -1,7 +1,7 @@ { "type": "plugin", "id": "@kbn/log-explorer-plugin", - "owner": "@elastic/infra-monitoring-ui", + "owner": "@elastic/obs-ux-logs-team", "description": "This plugin provides a LogExplorer component using the Discover customization framework, offering several affordances specifically designed for log consumption.", "plugin": { "id": "logExplorer", diff --git a/x-pack/plugins/log_explorer/public/components/log_explorer/log_explorer.tsx b/x-pack/plugins/log_explorer/public/components/log_explorer/log_explorer.tsx index 0612713085224..57736dd4b96dd 100644 --- a/x-pack/plugins/log_explorer/public/components/log_explorer/log_explorer.tsx +++ b/x-pack/plugins/log_explorer/public/components/log_explorer/log_explorer.tsx @@ -17,6 +17,7 @@ import { createLogExplorerProfileCustomizations } from '../../customizations/log import { createPropertyGetProxy } from '../../utils/proxies'; import { LogExplorerProfileContext } from '../../state_machines/log_explorer_profile'; import { LogExplorerStartDeps } from '../../types'; +import { LogExplorerCustomizations } from './types'; export interface CreateLogExplorerArgs { core: CoreStart; @@ -29,6 +30,7 @@ export interface LogExplorerStateContainer { } export interface LogExplorerProps { + customizations?: LogExplorerCustomizations; scopedHistory: ScopedHistory; state$?: BehaviorSubject; } @@ -44,10 +46,10 @@ export const createLogExplorer = ({ core, plugins }: CreateLogExplorerArgs) => { uiSettings: createUiSettingsServiceProxy(core.uiSettings), }; - return ({ scopedHistory, state$ }: LogExplorerProps) => { + return ({ customizations = {}, scopedHistory, state$ }: LogExplorerProps) => { const logExplorerCustomizations = useMemo( - () => [createLogExplorerProfileCustomizations({ core, plugins, state$ })], - [state$] + () => [createLogExplorerProfileCustomizations({ core, customizations, plugins, state$ })], + [customizations, state$] ); return ( diff --git a/x-pack/plugins/log_explorer/public/components/log_explorer/types.ts b/x-pack/plugins/log_explorer/public/components/log_explorer/types.ts new file mode 100644 index 0000000000000..2b366cce7c55c --- /dev/null +++ b/x-pack/plugins/log_explorer/public/components/log_explorer/types.ts @@ -0,0 +1,25 @@ +/* + * Copyright Elasticsearch B.V. and/or licensed to Elasticsearch B.V. under one + * or more contributor license agreements. Licensed under the Elastic License + * 2.0; you may not use this file except in compliance with the Elastic License + * 2.0. + */ + +import { DataTableRecord } from '@kbn/discover-utils/types'; + +export type RenderPreviousContent = () => React.ReactNode; + +export interface LogExplorerFlyoutContentProps { + doc: DataTableRecord; +} + +export type FlyoutRenderContent = ( + renderPreviousContent: RenderPreviousContent, + props: LogExplorerFlyoutContentProps +) => React.ReactNode; + +export interface LogExplorerCustomizations { + flyout?: { + renderContent?: FlyoutRenderContent; + }; +} diff --git a/x-pack/plugins/log_explorer/public/customizations/custom_flyout_content.tsx b/x-pack/plugins/log_explorer/public/customizations/custom_flyout_content.tsx index a4b473119744a..e7a5b7ed35915 100644 --- a/x-pack/plugins/log_explorer/public/customizations/custom_flyout_content.tsx +++ b/x-pack/plugins/log_explorer/public/customizations/custom_flyout_content.tsx @@ -5,10 +5,11 @@ * 2.0. */ -import React from 'react'; +import React, { useCallback } from 'react'; import { EuiFlexGroup, EuiFlexItem } from '@elastic/eui'; import { FlyoutDetail } from '../components/flyout_detail/flyout_detail'; import { FlyoutProps } from '../components/flyout_detail'; +import { useLogExplorerCustomizationsContext } from '../hooks/use_log_explorer_customizations'; export const CustomFlyoutContent = ({ actions, @@ -16,12 +17,28 @@ export const CustomFlyoutContent = ({ doc, renderDefaultContent, }: FlyoutProps) => { + const { flyout } = useLogExplorerCustomizationsContext(); + + const renderPreviousContent = useCallback( + () => ( + <> + {/* Apply custom Log Explorer detail */} + + + + + ), + [actions, dataView, doc] + ); + + const content = flyout?.renderContent + ? flyout?.renderContent(renderPreviousContent, { doc }) + : renderPreviousContent(); + return ( {/* Apply custom Log Explorer detail */} - - - + {content} {/* Restore default content */} {renderDefaultContent()} diff --git a/x-pack/plugins/log_explorer/public/customizations/log_explorer_profile.tsx b/x-pack/plugins/log_explorer/public/customizations/log_explorer_profile.tsx index 85d1284752977..628ff40babc22 100644 --- a/x-pack/plugins/log_explorer/public/customizations/log_explorer_profile.tsx +++ b/x-pack/plugins/log_explorer/public/customizations/log_explorer_profile.tsx @@ -14,6 +14,8 @@ import { LogExplorerProfileStateService } from '../state_machines/log_explorer_p import { LogExplorerStateContainer } from '../components/log_explorer'; import { LogExplorerStartDeps } from '../types'; import { useKibanaContextForPluginProvider } from '../utils/use_kibana'; +import { LogExplorerCustomizations } from '../components/log_explorer/types'; +import { LogExplorerCustomizationsProvider } from '../hooks/use_log_explorer_customizations'; const LazyCustomDatasetFilters = dynamic(() => import('./custom_dataset_filters')); const LazyCustomDatasetSelector = dynamic(() => import('./custom_dataset_selector')); @@ -21,12 +23,18 @@ const LazyCustomFlyoutContent = dynamic(() => import('./custom_flyout_content')) export interface CreateLogExplorerProfileCustomizationsDeps { core: CoreStart; + customizations: LogExplorerCustomizations; plugins: LogExplorerStartDeps; state$?: BehaviorSubject; } export const createLogExplorerProfileCustomizations = - ({ core, plugins, state$ }: CreateLogExplorerProfileCustomizationsDeps): CustomizationCallback => + ({ + core, + customizations: logExplorerCustomizations, + plugins, + state$, + }: CreateLogExplorerProfileCustomizationsDeps): CustomizationCallback => async ({ customizations, stateContainer }) => { const { data, dataViews, discover } = plugins; // Lazy load dependencies @@ -127,7 +135,9 @@ export const createLogExplorerProfileCustomizations = return ( - + + + ); }, diff --git a/x-pack/plugins/log_explorer/public/hooks/use_log_explorer_customizations.ts b/x-pack/plugins/log_explorer/public/hooks/use_log_explorer_customizations.ts new file mode 100644 index 0000000000000..0557e17761cb4 --- /dev/null +++ b/x-pack/plugins/log_explorer/public/hooks/use_log_explorer_customizations.ts @@ -0,0 +1,17 @@ +/* + * Copyright Elasticsearch B.V. and/or licensed to Elasticsearch B.V. under one + * or more contributor license agreements. Licensed under the Elastic License + * 2.0; you may not use this file except in compliance with the Elastic License + * 2.0. + */ +import createContainer from 'constate'; +import { LogExplorerCustomizations } from '../components/log_explorer/types'; + +interface UseLogExplorerCustomizationsDeps { + value: LogExplorerCustomizations; +} + +const useLogExplorerCustomizations = ({ value }: UseLogExplorerCustomizationsDeps) => value; + +export const [LogExplorerCustomizationsProvider, useLogExplorerCustomizationsContext] = + createContainer(useLogExplorerCustomizations); diff --git a/x-pack/plugins/log_explorer/public/index.ts b/x-pack/plugins/log_explorer/public/index.ts index 00750926517e6..1ca7f37aa4c9b 100644 --- a/x-pack/plugins/log_explorer/public/index.ts +++ b/x-pack/plugins/log_explorer/public/index.ts @@ -10,6 +10,10 @@ import type { LogExplorerConfig } from '../common/plugin_config'; import { LogExplorerPlugin } from './plugin'; export type { LogExplorerPluginSetup, LogExplorerPluginStart } from './types'; export type { LogExplorerStateContainer } from './components/log_explorer'; +export type { + LogExplorerCustomizations, + LogExplorerFlyoutContentProps, +} from './components/log_explorer/types'; export function plugin(context: PluginInitializerContext) { return new LogExplorerPlugin(context); diff --git a/x-pack/plugins/logs_shared/kibana.jsonc b/x-pack/plugins/logs_shared/kibana.jsonc index 051d1a452740e..b78503b140a71 100644 --- a/x-pack/plugins/logs_shared/kibana.jsonc +++ b/x-pack/plugins/logs_shared/kibana.jsonc @@ -1,7 +1,7 @@ { "type": "plugin", "id": "@kbn/logs-shared-plugin", - "owner": "@elastic/infra-monitoring-ui", + "owner": "@elastic/obs-ux-logs-team", "description": "Exposes the shared components and APIs to access and visualize logs.", "plugin": { "id": "logsShared", diff --git a/x-pack/plugins/logs_shared/public/components/log_ai_assistant/index.tsx b/x-pack/plugins/logs_shared/public/components/log_ai_assistant/index.tsx index a4df6c50cbafd..8cf9b2da45c06 100644 --- a/x-pack/plugins/logs_shared/public/components/log_ai_assistant/index.tsx +++ b/x-pack/plugins/logs_shared/public/components/log_ai_assistant/index.tsx @@ -4,22 +4,25 @@ * 2.0; you may not use this file except in compliance with the Elastic License * 2.0. */ -import React from 'react'; +import React, { ComponentType } from 'react'; import { Optional } from '@kbn/utility-types'; import { dynamic } from '../../../common/dynamic'; -import type { LogAIAssistantProps } from './log_ai_assistant'; +import type { LogAIAssistantDeps } from './log_ai_assistant'; export const LogAIAssistant = dynamic(() => import('./log_ai_assistant')); interface LogAIAssistantFactoryDeps { - observabilityAIAssistant: LogAIAssistantProps['aiAssistant']; + observabilityAIAssistant: LogAIAssistantDeps['observabilityAIAssistant']; } -export function createLogAIAssistant({ observabilityAIAssistant }: LogAIAssistantFactoryDeps) { - return ({ - aiAssistant = observabilityAIAssistant, - ...props - }: Optional) => ( - +export type LogAIAssistantComponent = ComponentType< + Optional +>; + +export function createLogAIAssistant({ + observabilityAIAssistant: aiAssistant, +}: LogAIAssistantFactoryDeps): LogAIAssistantComponent { + return ({ observabilityAIAssistant = aiAssistant, ...props }) => ( + ); } diff --git a/x-pack/plugins/logs_shared/public/components/log_ai_assistant/log_ai_assistant.mock.tsx b/x-pack/plugins/logs_shared/public/components/log_ai_assistant/log_ai_assistant.mock.tsx new file mode 100644 index 0000000000000..9ece10dff8188 --- /dev/null +++ b/x-pack/plugins/logs_shared/public/components/log_ai_assistant/log_ai_assistant.mock.tsx @@ -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. + */ + +import React from 'react'; + +export const createLogAIAssistantMock = () => jest.fn().mockReturnValue(
); diff --git a/x-pack/plugins/logs_shared/public/components/log_ai_assistant/log_ai_assistant.tsx b/x-pack/plugins/logs_shared/public/components/log_ai_assistant/log_ai_assistant.tsx index bce36a6d28dc6..335a02ab3a05e 100644 --- a/x-pack/plugins/logs_shared/public/components/log_ai_assistant/log_ai_assistant.tsx +++ b/x-pack/plugins/logs_shared/public/components/log_ai_assistant/log_ai_assistant.tsx @@ -12,6 +12,8 @@ import { type Message, ObservabilityAIAssistantPluginStart, MessageRole, + ObservabilityAIAssistantProvider, + useObservabilityAIAssistant, } from '@kbn/observability-ai-assistant-plugin/public'; import { LogEntryField } from '../../../common'; import { explainLogMessageTitle, similarLogMessagesTitle } from './translations'; @@ -21,11 +23,16 @@ export interface LogAIAssistantDocument { } export interface LogAIAssistantProps { - aiAssistant: ObservabilityAIAssistantPluginStart; doc: LogAIAssistantDocument | undefined; } -export function LogAIAssistant({ aiAssistant, doc }: LogAIAssistantProps) { +export interface LogAIAssistantDeps extends LogAIAssistantProps { + observabilityAIAssistant: ObservabilityAIAssistantPluginStart; +} + +export const LogAIAssistant = withProviders(({ doc }: LogAIAssistantProps) => { + const aiAssistant = useObservabilityAIAssistant(); + const explainLogMessageMessages = useMemo(() => { if (!doc) { return undefined; @@ -80,7 +87,20 @@ export function LogAIAssistant({ aiAssistant, doc }: LogAIAssistantProps) { ) : null} ); -} +}); // eslint-disable-next-line import/no-default-export export default LogAIAssistant; + +function withProviders(Component: React.FunctionComponent) { + return function ComponentWithProviders({ + observabilityAIAssistant, + ...props + }: LogAIAssistantDeps) { + return ( + + + + ); + }; +} diff --git a/x-pack/plugins/logs_shared/public/components/logging/log_entry_flyout/log_entry_flyout.tsx b/x-pack/plugins/logs_shared/public/components/logging/log_entry_flyout/log_entry_flyout.tsx index 62634f2aeba13..b66e864c2a499 100644 --- a/x-pack/plugins/logs_shared/public/components/logging/log_entry_flyout/log_entry_flyout.tsx +++ b/x-pack/plugins/logs_shared/public/components/logging/log_entry_flyout/log_entry_flyout.tsx @@ -184,7 +184,7 @@ export const LogEntryFlyout = ({ > - + diff --git a/x-pack/plugins/logs_shared/public/index.ts b/x-pack/plugins/logs_shared/public/index.ts index 873d202b1af7d..58f22fe48bccb 100644 --- a/x-pack/plugins/logs_shared/public/index.ts +++ b/x-pack/plugins/logs_shared/public/index.ts @@ -37,6 +37,7 @@ export { useLogSummary, WithSummary } from './containers/logs/log_summary'; export { useLogEntryFlyout } from './components/logging/log_entry_flyout'; // Shared components +export type { LogAIAssistantDocument } from './components/log_ai_assistant/log_ai_assistant'; export type { LogEntryStreamItem, LogEntryColumnWidths, diff --git a/x-pack/plugins/logs_shared/public/mocks.tsx b/x-pack/plugins/logs_shared/public/mocks.tsx index 963480d8fd90f..a9b0ebd6a6aa3 100644 --- a/x-pack/plugins/logs_shared/public/mocks.tsx +++ b/x-pack/plugins/logs_shared/public/mocks.tsx @@ -5,11 +5,13 @@ * 2.0. */ +import { createLogAIAssistantMock } from './components/log_ai_assistant/log_ai_assistant.mock'; import { createLogViewsServiceStartMock } from './services/log_views/log_views_service.mock'; import { LogsSharedClientStartExports } from './types'; export const createLogsSharedPluginStartMock = (): jest.Mocked => ({ logViews: createLogViewsServiceStartMock(), + LogAIAssistant: createLogAIAssistantMock(), }); export const _ensureTypeCompatibility = (): LogsSharedClientStartExports => diff --git a/x-pack/plugins/logs_shared/public/types.ts b/x-pack/plugins/logs_shared/public/types.ts index e67f83e4becc0..c0379c6fc21fb 100644 --- a/x-pack/plugins/logs_shared/public/types.ts +++ b/x-pack/plugins/logs_shared/public/types.ts @@ -17,6 +17,7 @@ import type { DataPublicPluginStart } from '@kbn/data-plugin/public'; import type { DataViewsPublicPluginStart } from '@kbn/data-views-plugin/public'; import { ObservabilityAIAssistantPluginStart } from '@kbn/observability-ai-assistant-plugin/public'; import { UiActionsStart } from '@kbn/ui-actions-plugin/public'; +import { LogAIAssistantComponent } from './components/log_ai_assistant'; // import type { OsqueryPluginStart } from '../../osquery/public'; import { LogViewsServiceSetup, LogViewsServiceStart } from './services/log_views'; @@ -27,6 +28,7 @@ export interface LogsSharedClientSetupExports { export interface LogsSharedClientStartExports { logViews: LogViewsServiceStart; + LogAIAssistant: LogAIAssistantComponent; } // eslint-disable-next-line @typescript-eslint/no-empty-interface diff --git a/x-pack/plugins/metrics_data_access/kibana.jsonc b/x-pack/plugins/metrics_data_access/kibana.jsonc index 6842ec7d4a724..10ddf6c04e21e 100644 --- a/x-pack/plugins/metrics_data_access/kibana.jsonc +++ b/x-pack/plugins/metrics_data_access/kibana.jsonc @@ -1,7 +1,7 @@ { "type": "plugin", "id": "@kbn/metrics-data-access-plugin", - "owner": "@elastic/infra-monitoring-ui", + "owner": "@elastic/obs-knowledge-team", "description": "Exposes utilities for accessing metrics data", "plugin": { "id": "metricsDataAccess", diff --git a/x-pack/plugins/monitoring/kibana.jsonc b/x-pack/plugins/monitoring/kibana.jsonc index 8da632c4b7d6f..4992da373a73d 100644 --- a/x-pack/plugins/monitoring/kibana.jsonc +++ b/x-pack/plugins/monitoring/kibana.jsonc @@ -1,7 +1,7 @@ { "type": "plugin", "id": "@kbn/monitoring-plugin", - "owner": "@elastic/infra-monitoring-ui", + "owner": "@elastic/obs-ux-infra_services-team", "plugin": { "id": "monitoring", "server": true, diff --git a/x-pack/plugins/monitoring_collection/kibana.jsonc b/x-pack/plugins/monitoring_collection/kibana.jsonc index 1c84d9ee4f84c..246dcce086a07 100644 --- a/x-pack/plugins/monitoring_collection/kibana.jsonc +++ b/x-pack/plugins/monitoring_collection/kibana.jsonc @@ -1,7 +1,7 @@ { "type": "plugin", "id": "@kbn/monitoring-collection-plugin", - "owner": "@elastic/infra-monitoring-ui", + "owner": "@elastic/obs-ux-infra_services-team", "plugin": { "id": "monitoringCollection", "server": true, diff --git a/x-pack/plugins/observability/kibana.jsonc b/x-pack/plugins/observability/kibana.jsonc index 86db25972fb1b..c03e0b499d424 100644 --- a/x-pack/plugins/observability/kibana.jsonc +++ b/x-pack/plugins/observability/kibana.jsonc @@ -1,7 +1,7 @@ { "type": "plugin", "id": "@kbn/observability-plugin", - "owner": "@elastic/actionable-observability", + "owner": "@elastic/obs-ux-management-team", "plugin": { "id": "observability", "server": true, diff --git a/x-pack/plugins/observability/public/pages/slo_edit/slo_edit.test.tsx b/x-pack/plugins/observability/public/pages/slo_edit/slo_edit.test.tsx index 21972da276691..8d4d45a08d709 100644 --- a/x-pack/plugins/observability/public/pages/slo_edit/slo_edit.test.tsx +++ b/x-pack/plugins/observability/public/pages/slo_edit/slo_edit.test.tsx @@ -5,8 +5,7 @@ * 2.0. */ -import { fireEvent, waitFor } from '@testing-library/dom'; -import { cleanup } from '@testing-library/react'; +import { fireEvent, waitFor, cleanup } from '@testing-library/react'; import { createBrowserHistory } from 'history'; import React from 'react'; import Router from 'react-router-dom'; diff --git a/x-pack/plugins/observability_ai_assistant/kibana.jsonc b/x-pack/plugins/observability_ai_assistant/kibana.jsonc index 3af934a10fcfa..291c7e658de18 100644 --- a/x-pack/plugins/observability_ai_assistant/kibana.jsonc +++ b/x-pack/plugins/observability_ai_assistant/kibana.jsonc @@ -1,7 +1,7 @@ { "type": "plugin", "id": "@kbn/observability-ai-assistant-plugin", - "owner": "@elastic/obs-ai-assistant", + "owner": "@elastic/obs-knowledge-team", "plugin": { "id": "observabilityAIAssistant", "server": true, diff --git a/x-pack/plugins/observability_log_explorer/kibana.jsonc b/x-pack/plugins/observability_log_explorer/kibana.jsonc index 7ac940de86dd4..72d03b82d3386 100644 --- a/x-pack/plugins/observability_log_explorer/kibana.jsonc +++ b/x-pack/plugins/observability_log_explorer/kibana.jsonc @@ -1,7 +1,7 @@ { "type": "plugin", "id": "@kbn/observability-log-explorer-plugin", - "owner": "@elastic/infra-monitoring-ui", + "owner": "@elastic/obs-ux-logs-team", "description": "This plugin exposes and registers observability log consumption features.", "plugin": { "id": "observabilityLogExplorer", @@ -15,6 +15,7 @@ "data", "discover", "logExplorer", + "logsShared", "observabilityShared", "share", "kibanaUtils", diff --git a/x-pack/plugins/observability_log_explorer/public/log_explorer_customizations/flyout_content.tsx b/x-pack/plugins/observability_log_explorer/public/log_explorer_customizations/flyout_content.tsx new file mode 100644 index 0000000000000..53d34a71a7237 --- /dev/null +++ b/x-pack/plugins/observability_log_explorer/public/log_explorer_customizations/flyout_content.tsx @@ -0,0 +1,51 @@ +/* + * Copyright Elasticsearch B.V. and/or licensed to Elasticsearch B.V. under one + * or more contributor license agreements. Licensed under the Elastic License + * 2.0; you may not use this file except in compliance with the Elastic License + * 2.0. + */ +import { EuiFlexItem } from '@elastic/eui'; +import { + LogExplorerCustomizations, + LogExplorerFlyoutContentProps, +} from '@kbn/log-explorer-plugin/public'; +import type { LogAIAssistantDocument } from '@kbn/logs-shared-plugin/public'; +import React, { useMemo } from 'react'; +import { useKibanaContextForPlugin } from '../utils/use_kibana'; + +const ObservabilityLogAIAssistant = ({ doc }: LogExplorerFlyoutContentProps) => { + const { services } = useKibanaContextForPlugin(); + const { LogAIAssistant } = services.logsShared; + + const mappedDoc = useMemo(() => mapDocToAIAssistantFormat(doc), [doc]); + + return ; +}; + +export const renderFlyoutContent: Required['flyout']['renderContent'] = ( + renderPreviousContent, + props +) => { + return ( + <> + {renderPreviousContent()} + + + + + ); +}; + +/** + * Utils + */ +const mapDocToAIAssistantFormat = (doc: LogExplorerFlyoutContentProps['doc']) => { + if (!doc) return; + + return { + fields: Object.entries(doc.flattened).map(([field, value]) => ({ + field, + value, + })) as LogAIAssistantDocument['fields'], + }; +}; diff --git a/x-pack/plugins/observability_log_explorer/public/log_explorer_customizations/index.ts b/x-pack/plugins/observability_log_explorer/public/log_explorer_customizations/index.ts new file mode 100644 index 0000000000000..a86b47e92cf01 --- /dev/null +++ b/x-pack/plugins/observability_log_explorer/public/log_explorer_customizations/index.ts @@ -0,0 +1,15 @@ +/* + * Copyright Elasticsearch B.V. and/or licensed to Elasticsearch B.V. under one + * or more contributor license agreements. Licensed under the Elastic License + * 2.0; you may not use this file except in compliance with the Elastic License + * 2.0. + */ + +import { LogExplorerCustomizations } from '@kbn/log-explorer-plugin/public'; +import { renderFlyoutContent } from './flyout_content'; + +export const createLogExplorerCustomizations = (): LogExplorerCustomizations => ({ + flyout: { + renderContent: renderFlyoutContent, + }, +}); diff --git a/x-pack/plugins/observability_log_explorer/public/routes/main/main_route.tsx b/x-pack/plugins/observability_log_explorer/public/routes/main/main_route.tsx index aece8474f0390..e17f92a46c23b 100644 --- a/x-pack/plugins/observability_log_explorer/public/routes/main/main_route.tsx +++ b/x-pack/plugins/observability_log_explorer/public/routes/main/main_route.tsx @@ -6,7 +6,7 @@ */ import { CoreStart } from '@kbn/core/public'; -import React, { useState } from 'react'; +import React, { useMemo, useState } from 'react'; import { BehaviorSubject } from 'rxjs'; import { LogExplorerTopNavMenu } from '../../components/log_explorer_top_nav_menu'; import { ObservabilityLogExplorerPageTemplate } from '../../components/page_template'; @@ -14,6 +14,7 @@ import { noBreadcrumbs, useBreadcrumbs } from '../../utils/breadcrumbs'; import { useKibanaContextForPlugin } from '../../utils/use_kibana'; import { ObservabilityLogExplorerAppMountParameters } from '../../types'; import { LazyOriginInterpreter } from '../../state_machines/origin_interpreter/src/lazy_component'; +import { createLogExplorerCustomizations } from '../../log_explorer_customizations'; export interface ObservablityLogExplorerMainRouteProps { appParams: ObservabilityLogExplorerAppMountParameters; core: CoreStart; @@ -31,6 +32,8 @@ export const ObservablityLogExplorerMainRoute = ({ const [state$] = useState(() => new BehaviorSubject({})); + const customizations = useMemo(() => createLogExplorerCustomizations(), []); + return ( <> - + ); diff --git a/x-pack/plugins/observability_log_explorer/public/types.ts b/x-pack/plugins/observability_log_explorer/public/types.ts index 82045faea76e8..8b315ad206ce4 100644 --- a/x-pack/plugins/observability_log_explorer/public/types.ts +++ b/x-pack/plugins/observability_log_explorer/public/types.ts @@ -12,6 +12,7 @@ import { ObservabilitySharedPluginStart } from '@kbn/observability-shared-plugin import { ServerlessPluginStart } from '@kbn/serverless/public'; import { SharePluginSetup, SharePluginStart } from '@kbn/share-plugin/public'; import { AppMountParameters, ScopedHistory } from '@kbn/core/public'; +import { LogsSharedClientStartExports } from '@kbn/logs-shared-plugin/public'; import { ObservabilityLogExplorerLocators, ObservabilityLogExplorerLocationState, @@ -33,6 +34,7 @@ export interface ObservabilityLogExplorerStartDeps { data: DataPublicPluginStart; discover: DiscoverStart; logExplorer: LogExplorerPluginStart; + logsShared: LogsSharedClientStartExports; observabilityShared: ObservabilitySharedPluginStart; serverless?: ServerlessPluginStart; share: SharePluginStart; diff --git a/x-pack/plugins/observability_log_explorer/tsconfig.json b/x-pack/plugins/observability_log_explorer/tsconfig.json index 7266e097dae62..109b54b929ec7 100644 --- a/x-pack/plugins/observability_log_explorer/tsconfig.json +++ b/x-pack/plugins/observability_log_explorer/tsconfig.json @@ -33,7 +33,8 @@ "@kbn/core-mount-utils-browser-internal", "@kbn/xstate-utils", "@kbn/shared-ux-utility", - "@kbn/ui-theme" + "@kbn/ui-theme", + "@kbn/logs-shared-plugin" ], "exclude": [ "target/**/*" diff --git a/x-pack/plugins/observability_onboarding/kibana.jsonc b/x-pack/plugins/observability_onboarding/kibana.jsonc index 5c1615c3a95ba..c2b89c8c9b4fa 100644 --- a/x-pack/plugins/observability_onboarding/kibana.jsonc +++ b/x-pack/plugins/observability_onboarding/kibana.jsonc @@ -1,7 +1,7 @@ { "type": "plugin", "id": "@kbn/observability-onboarding-plugin", - "owner": "@elastic/apm-ui", + "owner": "@elastic/obs-ux-logs-team", "plugin": { "id": "observabilityOnboarding", "server": true, diff --git a/x-pack/plugins/osquery/cypress/e2e/all/alerts_response_actions_form.cy.ts b/x-pack/plugins/osquery/cypress/e2e/all/alerts_response_actions_form.cy.ts index 15fb98540e438..cb4ce27a69031 100644 --- a/x-pack/plugins/osquery/cypress/e2e/all/alerts_response_actions_form.cy.ts +++ b/x-pack/plugins/osquery/cypress/e2e/all/alerts_response_actions_form.cy.ts @@ -63,6 +63,7 @@ describe('Alert Event Details - Response Actions Form', { tags: ['@ess', '@serve cy.getBySel('globalLoadingIndicator').should('not.exist'); closeDateTabIfVisible(); cy.getBySel('edit-rule-actions-tab').click(); + cy.getBySel('globalLoadingIndicator').should('not.exist'); cy.contains('Response actions are run on each rule execution.'); cy.getBySel(OSQUERY_RESPONSE_ACTION_ADD_BUTTON).click(); cy.getBySel(RESPONSE_ACTIONS_ITEM_0).within(() => { diff --git a/x-pack/plugins/osquery/cypress/tasks/response_actions.ts b/x-pack/plugins/osquery/cypress/tasks/response_actions.ts index 3f59ebca9f560..d686392431b7a 100644 --- a/x-pack/plugins/osquery/cypress/tasks/response_actions.ts +++ b/x-pack/plugins/osquery/cypress/tasks/response_actions.ts @@ -45,6 +45,7 @@ export const checkOsqueryResponseActionsPermissions = (enabled: boolean) => { cy.getBySel('globalLoadingIndicator').should('not.exist'); closeDateTabIfVisible(); cy.getBySel('edit-rule-actions-tab').click(); + cy.getBySel('globalLoadingIndicator').should('not.exist'); cy.contains('Response actions are run on each rule execution.'); cy.getBySel(OSQUERY_RESPONSE_ACTION_ADD_BUTTON).click(); if (enabled) { diff --git a/x-pack/plugins/profiling/kibana.jsonc b/x-pack/plugins/profiling/kibana.jsonc index 104196bababc9..296b4e40bb822 100644 --- a/x-pack/plugins/profiling/kibana.jsonc +++ b/x-pack/plugins/profiling/kibana.jsonc @@ -1,7 +1,7 @@ { "type": "plugin", "id": "@kbn/profiling-plugin", - "owner": "@elastic/profiling-ui", + "owner": "@elastic/obs-ux-infra_services-team", "plugin": { "id": "profiling", "server": true, diff --git a/x-pack/plugins/profiling_data_access/kibana.jsonc b/x-pack/plugins/profiling_data_access/kibana.jsonc index a6bcd9f7ecff4..a2c3fb4cb267b 100644 --- a/x-pack/plugins/profiling_data_access/kibana.jsonc +++ b/x-pack/plugins/profiling_data_access/kibana.jsonc @@ -1,7 +1,7 @@ { "type": "plugin", "id": "@kbn/profiling-data-access-plugin", - "owner": "@elastic/profiling-ui", + "owner": "@elastic/obs-ux-infra_services-team", "plugin": { "id": "profilingDataAccess", "server": true, diff --git a/x-pack/plugins/rule_registry/kibana.jsonc b/x-pack/plugins/rule_registry/kibana.jsonc index d5c867247e811..28612bff2b9cc 100644 --- a/x-pack/plugins/rule_registry/kibana.jsonc +++ b/x-pack/plugins/rule_registry/kibana.jsonc @@ -3,7 +3,7 @@ "id": "@kbn/rule-registry-plugin", "owner": [ "@elastic/response-ops", - "@elastic/actionable-observability" + "@elastic/obs-ux-management-team" ], "plugin": { "id": "ruleRegistry", diff --git a/x-pack/plugins/security_solution/public/common/components/event_details/event_details.test.tsx b/x-pack/plugins/security_solution/public/common/components/event_details/event_details.test.tsx index 7323c293cd94c..edc72e92ff153 100644 --- a/x-pack/plugins/security_solution/public/common/components/event_details/event_details.test.tsx +++ b/x-pack/plugins/security_solution/public/common/components/event_details/event_details.test.tsx @@ -5,7 +5,7 @@ * 2.0. */ -import { waitFor } from '@testing-library/dom'; +import { waitFor } from '@testing-library/react'; import { mount } from 'enzyme'; import type { ReactWrapper } from 'enzyme'; import React from 'react'; diff --git a/x-pack/plugins/security_solution/public/common/components/ml/score/anomaly_score.test.tsx b/x-pack/plugins/security_solution/public/common/components/ml/score/anomaly_score.test.tsx index 4bdbbdca8bdca..d8b43fa9a603b 100644 --- a/x-pack/plugins/security_solution/public/common/components/ml/score/anomaly_score.test.tsx +++ b/x-pack/plugins/security_solution/public/common/components/ml/score/anomaly_score.test.tsx @@ -15,7 +15,7 @@ import { mockAnomalies } from '../mock'; import { TestProviders } from '../../../mock/test_providers'; import { useMountAppended } from '../../../utils/use_mount_appended'; import type { Anomalies } from '../types'; -import { waitFor } from '@testing-library/dom'; +import { waitFor } from '@testing-library/react'; jest.mock('../../../lib/kibana'); diff --git a/x-pack/plugins/security_solution/public/common/components/ml/score/anomaly_scores.test.tsx b/x-pack/plugins/security_solution/public/common/components/ml/score/anomaly_scores.test.tsx index 6a72d72a9eb59..b54ec85bab0e4 100644 --- a/x-pack/plugins/security_solution/public/common/components/ml/score/anomaly_scores.test.tsx +++ b/x-pack/plugins/security_solution/public/common/components/ml/score/anomaly_scores.test.tsx @@ -16,7 +16,7 @@ import { TestProviders } from '../../../mock/test_providers'; import { getEmptyValue } from '../../empty_value'; import type { Anomalies } from '../types'; import { useMountAppended } from '../../../utils/use_mount_appended'; -import { waitFor } from '@testing-library/dom'; +import { waitFor } from '@testing-library/react'; jest.mock('../../../lib/kibana'); diff --git a/x-pack/plugins/security_solution/public/common/components/ml/score/create_descriptions_list.test.tsx b/x-pack/plugins/security_solution/public/common/components/ml/score/create_descriptions_list.test.tsx index c9de8aad04de8..832c60c69be87 100644 --- a/x-pack/plugins/security_solution/public/common/components/ml/score/create_descriptions_list.test.tsx +++ b/x-pack/plugins/security_solution/public/common/components/ml/score/create_descriptions_list.test.tsx @@ -11,7 +11,7 @@ import { mockAnomalies } from '../mock'; import { createDescriptionList } from './create_description_list'; import { EuiDescriptionList } from '@elastic/eui'; import type { Anomaly } from '../types'; -import { waitFor } from '@testing-library/dom'; +import { waitFor } from '@testing-library/react'; jest.mock('../../../lib/kibana'); diff --git a/x-pack/plugins/security_solution/public/common/components/popover_items/index.test.tsx b/x-pack/plugins/security_solution/public/common/components/popover_items/index.test.tsx index 8d7123bfe6d66..58584f4325d4e 100644 --- a/x-pack/plugins/security_solution/public/common/components/popover_items/index.test.tsx +++ b/x-pack/plugins/security_solution/public/common/components/popover_items/index.test.tsx @@ -10,8 +10,7 @@ import React from 'react'; import type { PopoverItemsProps } from '.'; import { PopoverItems } from '.'; import { TestProviders } from '../../mock'; -import { render, screen } from '@testing-library/react'; -import { within } from '@testing-library/dom'; +import { render, screen, within } from '@testing-library/react'; import { waitForEuiPopoverOpen } from '@elastic/eui/lib/test/rtl'; const mockTags = ['Elastic', 'Endpoint', 'Data Protection', 'ML', 'Continuous Monitoring']; diff --git a/x-pack/plugins/security_solution/public/common/components/sourcerer/index.test.tsx b/x-pack/plugins/security_solution/public/common/components/sourcerer/index.test.tsx index ceab08373993a..ebda7e6748ebd 100644 --- a/x-pack/plugins/security_solution/public/common/components/sourcerer/index.test.tsx +++ b/x-pack/plugins/security_solution/public/common/components/sourcerer/index.test.tsx @@ -22,7 +22,7 @@ import { } from '../../mock'; import { createStore } from '../../store'; import type { EuiSuperSelectOption } from '@elastic/eui/src/components/form/super_select/super_select_control'; -import { waitFor } from '@testing-library/dom'; +import { waitFor } from '@testing-library/react'; import { useSourcererDataView } from '../../containers/sourcerer'; import { useSignalHelpers } from '../../containers/sourcerer/use_signal_helpers'; import { TimelineId } from '../../../../common/types/timeline'; diff --git a/x-pack/plugins/security_solution/public/detection_engine/rule_exceptions/components/flyout_components/add_to_rules_table/use_add_to_rules_table.test.tsx b/x-pack/plugins/security_solution/public/detection_engine/rule_exceptions/components/flyout_components/add_to_rules_table/use_add_to_rules_table.test.tsx index 7afa5e5a7eef0..8862c626ea6e4 100644 --- a/x-pack/plugins/security_solution/public/detection_engine/rule_exceptions/components/flyout_components/add_to_rules_table/use_add_to_rules_table.test.tsx +++ b/x-pack/plugins/security_solution/public/detection_engine/rule_exceptions/components/flyout_components/add_to_rules_table/use_add_to_rules_table.test.tsx @@ -6,9 +6,8 @@ */ import React from 'react'; -import { fireEvent, render as rTLRender } from '@testing-library/react'; -import { waitFor } from '@testing-library/dom'; -import { act, renderHook } from '@testing-library/react-hooks'; +import { fireEvent, render as rTLRender, waitFor, act } from '@testing-library/react'; +import { renderHook } from '@testing-library/react-hooks'; import type { EuiTableFieldDataColumnType } from '@elastic/eui'; import type { Rule } from '../../../../rule_management/logic/types'; import { getRulesSchemaMock } from '../../../../../../common/api/detection_engine/model/rule_schema/mocks'; diff --git a/x-pack/plugins/security_solution/public/management/components/console/mocks.tsx b/x-pack/plugins/security_solution/public/management/components/console/mocks.tsx index ac729f898c6be..d756e6aaea2e5 100644 --- a/x-pack/plugins/security_solution/public/management/components/console/mocks.tsx +++ b/x-pack/plugins/security_solution/public/management/components/console/mocks.tsx @@ -10,8 +10,7 @@ import React, { memo, useEffect } from 'react'; import { EuiCode } from '@elastic/eui'; import userEvent from '@testing-library/user-event'; -import { act } from '@testing-library/react'; -import { within } from '@testing-library/dom'; +import { act, within } from '@testing-library/react'; import { convertToTestId } from './components/command_list'; import { Console } from './console'; import type { diff --git a/x-pack/plugins/security_solution/public/management/pages/endpoint_hosts/view/components/integration_tests/search_bar.test.tsx b/x-pack/plugins/security_solution/public/management/pages/endpoint_hosts/view/components/integration_tests/search_bar.test.tsx index ab0a856ff1fa6..f053ee5ef8d68 100644 --- a/x-pack/plugins/security_solution/public/management/pages/endpoint_hosts/view/components/integration_tests/search_bar.test.tsx +++ b/x-pack/plugins/security_solution/public/management/pages/endpoint_hosts/view/components/integration_tests/search_bar.test.tsx @@ -9,10 +9,9 @@ import React from 'react'; import type { AppContextTestRender } from '../../../../../../common/mock/endpoint'; import { createAppRootMockRenderer } from '../../../../../../common/mock/endpoint'; import { endpointPageHttpMock } from '../../../mocks'; -import { act, waitFor, cleanup } from '@testing-library/react'; +import { act, waitFor, cleanup, fireEvent } from '@testing-library/react'; import { getEndpointListPath } from '../../../../../common/routing'; import { AdminSearchBar } from '../search_bar'; -import { fireEvent } from '@testing-library/dom'; import { uiQueryParams } from '../../../store/selectors'; import type { EndpointIndexUIQueryParams } from '../../../types'; diff --git a/x-pack/plugins/security_solution/public/management/pages/policy/view/artifacts/assignable/policy_artifacts_assignable_list.test.tsx b/x-pack/plugins/security_solution/public/management/pages/policy/view/artifacts/assignable/policy_artifacts_assignable_list.test.tsx index aa57df82276c6..c1f95b1f4d067 100644 --- a/x-pack/plugins/security_solution/public/management/pages/policy/view/artifacts/assignable/policy_artifacts_assignable_list.test.tsx +++ b/x-pack/plugins/security_solution/public/management/pages/policy/view/artifacts/assignable/policy_artifacts_assignable_list.test.tsx @@ -10,7 +10,7 @@ import { PolicyArtifactsAssignableList } from './policy_artifacts_assignable_lis import * as reactTestingLibrary from '@testing-library/react'; import type { AppContextTestRender } from '../../../../../../common/mock/endpoint'; import { createAppRootMockRenderer } from '../../../../../../common/mock/endpoint'; -import { fireEvent } from '@testing-library/dom'; +import { fireEvent } from '@testing-library/react'; import { getMockListResponse } from '../../../test_utils'; describe('Policy artifacts list', () => { diff --git a/x-pack/plugins/security_solution/public/management/pages/policy/view/policy_settings_form/components/advanced_section.test.tsx b/x-pack/plugins/security_solution/public/management/pages/policy/view/policy_settings_form/components/advanced_section.test.tsx index 0eb65818b9347..6688c12c7f853 100644 --- a/x-pack/plugins/security_solution/public/management/pages/policy/view/policy_settings_form/components/advanced_section.test.tsx +++ b/x-pack/plugins/security_solution/public/management/pages/policy/view/policy_settings_form/components/advanced_section.test.tsx @@ -17,7 +17,7 @@ import type { AdvancedSectionProps } from './advanced_section'; import { AdvancedSection } from './advanced_section'; import userEvent from '@testing-library/user-event'; import { AdvancedPolicySchema } from '../../../models/advanced_policy_schema'; -import { within } from '@testing-library/dom'; +import { within } from '@testing-library/react'; import { set } from 'lodash'; jest.mock('../../../../../../common/hooks/use_license'); diff --git a/x-pack/plugins/security_solution/public/management/pages/policy/view/policy_settings_form/components/event_collection_card.test.tsx b/x-pack/plugins/security_solution/public/management/pages/policy/view/policy_settings_form/components/event_collection_card.test.tsx index eeaa22aa14f6b..54ade4d11b4dd 100644 --- a/x-pack/plugins/security_solution/public/management/pages/policy/view/policy_settings_form/components/event_collection_card.test.tsx +++ b/x-pack/plugins/security_solution/public/management/pages/policy/view/policy_settings_form/components/event_collection_card.test.tsx @@ -18,7 +18,7 @@ import { OperatingSystem } from '@kbn/securitysolution-utils'; import { expectIsViewOnly, exactMatchText } from '../mocks'; import userEvent from '@testing-library/user-event'; import { cloneDeep, set } from 'lodash'; -import { within } from '@testing-library/dom'; +import { within } from '@testing-library/react'; describe('Policy Event Collection Card common component', () => { let formProps: EventCollectionCardProps; diff --git a/x-pack/plugins/security_solution/public/timelines/components/timeline/query_bar/index.test.tsx b/x-pack/plugins/security_solution/public/timelines/components/timeline/query_bar/index.test.tsx index 153b24dcf0bf8..cd0a21d99cdfe 100644 --- a/x-pack/plugins/security_solution/public/timelines/components/timeline/query_bar/index.test.tsx +++ b/x-pack/plugins/security_solution/public/timelines/components/timeline/query_bar/index.test.tsx @@ -21,7 +21,7 @@ import { buildGlobalQuery } from '../helpers'; import type { QueryBarTimelineComponentProps } from '.'; import { QueryBarTimeline, getDataProviderFilter, TIMELINE_FILTER_DROP_AREA } from '.'; -import { waitFor } from '@testing-library/dom'; +import { waitFor } from '@testing-library/react'; const mockUiSettingsForFilterManager = coreMock.createStart().uiSettings; diff --git a/x-pack/plugins/serverless_observability/kibana.jsonc b/x-pack/plugins/serverless_observability/kibana.jsonc index 0c68668e473ea..692d721c20a30 100644 --- a/x-pack/plugins/serverless_observability/kibana.jsonc +++ b/x-pack/plugins/serverless_observability/kibana.jsonc @@ -3,7 +3,7 @@ "id": "@kbn/serverless-observability", "owner": [ "@elastic/appex-sharedux", - "@elastic/apm-ui" + "@elastic/obs-ux-management-team" ], "description": "Serverless customizations for observability.", "plugin": { diff --git a/x-pack/plugins/serverless_search/public/layout/nav.tsx b/x-pack/plugins/serverless_search/public/layout/nav.tsx index 3aaa1ae62884c..7d4b2fd7d0fd1 100644 --- a/x-pack/plugins/serverless_search/public/layout/nav.tsx +++ b/x-pack/plugins/serverless_search/public/layout/nav.tsx @@ -15,6 +15,7 @@ import React from 'react'; import { i18n } from '@kbn/i18n'; import type { ServerlessPluginStart } from '@kbn/serverless/public'; import type { CloudStart } from '@kbn/cloud-plugin/public'; +import { CONNECTORS_LABEL } from '../../common/i18n_string'; const navigationTree: NavigationTreeDefinition = { body: [ @@ -37,79 +38,60 @@ const navigationTree: NavigationTreeDefinition = { getIsActive: ({ pathNameSerialized, prepend }) => { return pathNameSerialized.startsWith(prepend('/app/dev_tools')); }, + spaceBefore: 'l', }, { - id: 'explore', - title: i18n.translate('xpack.serverlessSearch.nav.explore', { - defaultMessage: 'Explore', + link: 'discover', + spaceBefore: 'm', + }, + { + link: 'dashboards', + getIsActive: ({ pathNameSerialized, prepend }) => { + return pathNameSerialized.startsWith(prepend('/app/dashboards')); + }, + }, + { + link: 'visualize', + title: i18n.translate('xpack.serverlessSearch.nav.visualize', { + defaultMessage: 'Visualizations', }), - children: [ - { - link: 'discover', - }, - { - link: 'dashboards', - getIsActive: ({ pathNameSerialized, prepend }) => { - return pathNameSerialized.startsWith(prepend('/app/dashboards')); - }, - }, - { - link: 'visualize', - title: i18n.translate('xpack.serverlessSearch.nav.visualize', { - defaultMessage: 'Visualizations', - }), - getIsActive: ({ pathNameSerialized, prepend }) => { - return ( - pathNameSerialized.startsWith(prepend('/app/visualize')) || - pathNameSerialized.startsWith(prepend('/app/lens')) || - pathNameSerialized.startsWith(prepend('/app/maps')) - ); - }, - }, - { - link: 'management:triggersActions', - title: i18n.translate('xpack.serverlessSearch.nav.alerts', { - defaultMessage: 'Alerts', - }), - }, - ], + getIsActive: ({ pathNameSerialized, prepend }) => { + return ( + pathNameSerialized.startsWith(prepend('/app/visualize')) || + pathNameSerialized.startsWith(prepend('/app/lens')) || + pathNameSerialized.startsWith(prepend('/app/maps')) + ); + }, }, { - id: 'content', - title: i18n.translate('xpack.serverlessSearch.nav.content', { - defaultMessage: 'Content', + link: 'management:triggersActions', + title: i18n.translate('xpack.serverlessSearch.nav.alerts', { + defaultMessage: 'Alerts', }), - children: [ - { - title: i18n.translate('xpack.serverlessSearch.nav.content.indices', { - defaultMessage: 'Index Management', - }), - link: 'management:index_management', - breadcrumbStatus: - 'hidden' /* management sub-pages set their breadcrumbs themselves */, - }, - { - title: i18n.translate('xpack.serverlessSearch.nav.content.pipelines', { - defaultMessage: 'Pipelines', - }), - link: 'management:ingest_pipelines', - breadcrumbStatus: - 'hidden' /* management sub-pages set their breadcrumbs themselves */, - }, - ], }, { - id: 'security', - title: i18n.translate('xpack.serverlessSearch.nav.security', { - defaultMessage: 'Security', + title: i18n.translate('xpack.serverlessSearch.nav.content.indices', { + defaultMessage: 'Index Management', }), - children: [ - { - link: 'management:api_keys', - breadcrumbStatus: - 'hidden' /* management sub-pages set their breadcrumbs themselves */, - }, - ], + link: 'management:index_management', + breadcrumbStatus: 'hidden' /* management sub-pages set their breadcrumbs themselves */, + spaceBefore: 'm', + }, + { + title: i18n.translate('xpack.serverlessSearch.nav.content.pipelines', { + defaultMessage: 'Pipelines', + }), + link: 'management:ingest_pipelines', + breadcrumbStatus: 'hidden' /* management sub-pages set their breadcrumbs themselves */, + }, + { + title: CONNECTORS_LABEL, + link: 'serverlessConnectors', + }, + { + link: 'management:api_keys', + breadcrumbStatus: 'hidden' /* management sub-pages set their breadcrumbs themselves */, + spaceBefore: 'm', }, ], }, diff --git a/x-pack/plugins/session_view/public/components/detail_panel_alert_tab/index.test.tsx b/x-pack/plugins/session_view/public/components/detail_panel_alert_tab/index.test.tsx index 989c4fd45cfbc..b729824478e2c 100644 --- a/x-pack/plugins/session_view/public/components/detail_panel_alert_tab/index.test.tsx +++ b/x-pack/plugins/session_view/public/components/detail_panel_alert_tab/index.test.tsx @@ -10,7 +10,7 @@ import React from 'react'; import { AppContextTestRender, createAppRootMockRenderer } from '../../test'; import { DetailPanelAlertTab } from '.'; import { mockAlerts } from '../../../common/mocks/constants/session_view_process.mock'; -import { fireEvent } from '@testing-library/dom'; +import { fireEvent } from '@testing-library/react'; import { INVESTIGATED_ALERT_TEST_ID, VIEW_MODE_TOGGLE, ALERTS_TAB_EMPTY_STATE_TEST_ID } from '.'; import { ALERT_LIST_ITEM_TEST_ID, diff --git a/x-pack/plugins/session_view/public/components/session_view_search_bar/index.test.tsx b/x-pack/plugins/session_view/public/components/session_view_search_bar/index.test.tsx index 8b3498f2a11b8..4bfd695530b43 100644 --- a/x-pack/plugins/session_view/public/components/session_view_search_bar/index.test.tsx +++ b/x-pack/plugins/session_view/public/components/session_view_search_bar/index.test.tsx @@ -10,7 +10,7 @@ import { processMock } from '../../../common/mocks/constants/session_view_proces import { AppContextTestRender, createAppRootMockRenderer } from '../../test'; import { SessionViewSearchBar } from '.'; import userEvent from '@testing-library/user-event'; -import { fireEvent } from '@testing-library/dom'; +import { fireEvent } from '@testing-library/react'; describe('SessionViewSearchBar component', () => { let render: () => ReturnType; diff --git a/x-pack/plugins/stack_connectors/public/connector_types/swimlane/swimlane_connectors.test.tsx b/x-pack/plugins/stack_connectors/public/connector_types/swimlane/swimlane_connectors.test.tsx index 643d43d8b10b3..cb6652052d65e 100644 --- a/x-pack/plugins/stack_connectors/public/connector_types/swimlane/swimlane_connectors.test.tsx +++ b/x-pack/plugins/stack_connectors/public/connector_types/swimlane/swimlane_connectors.test.tsx @@ -7,14 +7,12 @@ import React from 'react'; import { mountWithIntl, nextTick } from '@kbn/test-jest-helpers'; -import { act } from 'react-dom/test-utils'; import SwimlaneActionConnectorFields from './swimlane_connectors'; import { useGetApplication } from './use_get_application'; import { applicationFields, mappings } from './mocks'; import { ConnectorFormTestProvider } from '../lib/test_utils'; -import { waitFor } from '@testing-library/dom'; +import { waitFor, render, act } from '@testing-library/react'; import userEvent from '@testing-library/user-event'; -import { render } from '@testing-library/react'; jest.mock('@kbn/triggers-actions-ui-plugin/public/common/lib/kibana'); jest.mock('./use_get_application'); diff --git a/x-pack/plugins/synthetics/kibana.jsonc b/x-pack/plugins/synthetics/kibana.jsonc index d03d0d384938f..9e85c2ec6c604 100644 --- a/x-pack/plugins/synthetics/kibana.jsonc +++ b/x-pack/plugins/synthetics/kibana.jsonc @@ -1,7 +1,7 @@ { "type": "plugin", "id": "@kbn/synthetics-plugin", - "owner": "@elastic/uptime", + "owner": "@elastic/obs-ux-infra_services-team", "description": "This plugin visualizes data from Synthetics and Heartbeat, and integrates with other Observability solutions.", "plugin": { "id": "synthetics", diff --git a/x-pack/plugins/synthetics/public/apps/synthetics/components/common/date_picker/synthetics_date_picker.test.tsx b/x-pack/plugins/synthetics/public/apps/synthetics/components/common/date_picker/synthetics_date_picker.test.tsx index a78710dd9994e..1a0ec3002655a 100644 --- a/x-pack/plugins/synthetics/public/apps/synthetics/components/common/date_picker/synthetics_date_picker.test.tsx +++ b/x-pack/plugins/synthetics/public/apps/synthetics/components/common/date_picker/synthetics_date_picker.test.tsx @@ -10,7 +10,7 @@ import { SyntheticsDatePicker } from './synthetics_date_picker'; import { startPlugins } from '../../../utils/testing/__mocks__/synthetics_plugin_start_mock'; import { createMemoryHistory } from 'history'; import { render } from '../../../utils/testing'; -import { fireEvent } from '@testing-library/dom'; +import { fireEvent } from '@testing-library/react'; describe('SyntheticsDatePicker component', () => { jest.setTimeout(10_000); diff --git a/x-pack/plugins/synthetics/public/apps/synthetics/components/getting_started/simple_monitor_form.test.tsx b/x-pack/plugins/synthetics/public/apps/synthetics/components/getting_started/simple_monitor_form.test.tsx index 9c392b6a409f0..322cc2c653ef9 100644 --- a/x-pack/plugins/synthetics/public/apps/synthetics/components/getting_started/simple_monitor_form.test.tsx +++ b/x-pack/plugins/synthetics/public/apps/synthetics/components/getting_started/simple_monitor_form.test.tsx @@ -12,10 +12,9 @@ import { WEBSITE_URL_HELP_TEXT, WEBSITE_URL_LABEL, } from './simple_monitor_form'; -import { screen } from '@testing-library/react'; import { render } from '../../utils/testing'; import React from 'react'; -import { act, fireEvent, waitFor } from '@testing-library/react'; +import { act, fireEvent, waitFor, screen } from '@testing-library/react'; import { syntheticsTestSubjects } from '../../../../../common/constants/data_test_subjects'; import { apiService } from '../../../../utils/api_service'; import * as reduxHooks from 'react-redux'; diff --git a/x-pack/plugins/synthetics/public/apps/synthetics/components/step_details_page/step_waterfall_chart/waterfall/waterfall_marker/waterfall_marker_icon.test.tsx b/x-pack/plugins/synthetics/public/apps/synthetics/components/step_details_page/step_waterfall_chart/waterfall/waterfall_marker/waterfall_marker_icon.test.tsx index 3ebbb2b1c6b57..a91da97ce3a5c 100644 --- a/x-pack/plugins/synthetics/public/apps/synthetics/components/step_details_page/step_waterfall_chart/waterfall/waterfall_marker/waterfall_marker_icon.test.tsx +++ b/x-pack/plugins/synthetics/public/apps/synthetics/components/step_details_page/step_waterfall_chart/waterfall/waterfall_marker/waterfall_marker_icon.test.tsx @@ -6,7 +6,7 @@ */ import React from 'react'; -import { fireEvent, waitFor } from '@testing-library/dom'; +import { fireEvent, waitFor } from '@testing-library/react'; import { WaterfallMarkerIcon } from './waterfall_marker_icon'; import { TestWrapper } from './waterfall_marker_test_helper'; import { render } from '../../../../../utils/testing'; diff --git a/x-pack/plugins/synthetics/public/apps/synthetics/utils/testing/rtl_helpers.tsx b/x-pack/plugins/synthetics/public/apps/synthetics/utils/testing/rtl_helpers.tsx index 27452ce3254c2..552229fe47346 100644 --- a/x-pack/plugins/synthetics/public/apps/synthetics/utils/testing/rtl_helpers.tsx +++ b/x-pack/plugins/synthetics/public/apps/synthetics/utils/testing/rtl_helpers.tsx @@ -6,12 +6,14 @@ */ import React, { ReactElement, ReactNode } from 'react'; +import { i18n } from '@kbn/i18n'; import { of } from 'rxjs'; // eslint-disable-next-line import/no-extraneous-dependencies import { render as reactTestLibRender, MatcherFunction, RenderOptions, + configure, } from '@testing-library/react'; import { Router } from '@kbn/shared-ux-router'; import { Route } from '@kbn/shared-ux-router'; @@ -21,8 +23,6 @@ import { createMemoryHistory, History } from 'history'; import { CoreStart } from '@kbn/core/public'; import { I18nProvider } from '@kbn/i18n-react'; import { coreMock } from '@kbn/core/public/mocks'; -// eslint-disable-next-line import/no-extraneous-dependencies -import { configure } from '@testing-library/dom'; import { EuiThemeProvider } from '@kbn/kibana-react-plugin/common'; import { IStorageWrapper } from '@kbn/kibana-utils-plugin/public'; import { KibanaContextProvider, KibanaServices } from '@kbn/kibana-react-plugin/public'; @@ -161,7 +161,13 @@ export const mockCore: () => Partial = () => { exploratoryView: { createExploratoryViewUrl: jest.fn(), getAppDataView: jest.fn(), - ExploratoryViewEmbeddable: () =>
Embeddable exploratory view
, + ExploratoryViewEmbeddable: () => ( +
+ {i18n.translate('xpack.synthetics.core.div.embeddableExploratoryViewLabel', { + defaultMessage: 'Embeddable exploratory view', + })} +
+ ), }, }; diff --git a/x-pack/plugins/transform/public/app/sections/transform_management/components/transform_list/expanded_row.test.tsx b/x-pack/plugins/transform/public/app/sections/transform_management/components/transform_list/expanded_row.test.tsx index 370d7c2da05d5..4f9eacc38ecc5 100644 --- a/x-pack/plugins/transform/public/app/sections/transform_management/components/transform_list/expanded_row.test.tsx +++ b/x-pack/plugins/transform/public/app/sections/transform_management/components/transform_list/expanded_row.test.tsx @@ -5,14 +5,13 @@ * 2.0. */ -import { render, fireEvent, screen, waitFor } from '@testing-library/react'; +import { render, fireEvent, screen, waitFor, within } from '@testing-library/react'; import React from 'react'; import moment from 'moment-timezone'; import { TransformListRow } from '../../../../common'; import { ExpandedRow } from './expanded_row'; import transformListRow from '../../../../common/__mocks__/transform_list_row.json'; -import { within } from '@testing-library/dom'; jest.mock('../../../../../shared_imports'); jest.mock('../../../../app_dependencies'); diff --git a/x-pack/plugins/translations/translations/fr-FR.json b/x-pack/plugins/translations/translations/fr-FR.json index c06aff873c9bf..9024c08ddcc3d 100644 --- a/x-pack/plugins/translations/translations/fr-FR.json +++ b/x-pack/plugins/translations/translations/fr-FR.json @@ -37250,16 +37250,13 @@ "xpack.serverlessSearch.languages.ruby.githubLabel": "elasticsearch-serverless-ruby", "xpack.serverlessSearch.learnMore": "En savoir plus", "xpack.serverlessSearch.nav.alerts": "Alertes", - "xpack.serverlessSearch.nav.content": "Contenu", "xpack.serverlessSearch.nav.content.indices": "Gestion des index", "xpack.serverlessSearch.nav.content.pipelines": "Pipelines", "xpack.serverlessSearch.nav.devTools": "Outils de développement", - "xpack.serverlessSearch.nav.explore": "Explorer", "xpack.serverlessSearch.nav.gettingStarted": "Premiers pas", "xpack.serverlessSearch.nav.mngt": "Gestion", "xpack.serverlessSearch.nav.performance": "Performances", "xpack.serverlessSearch.nav.projectSettings": "Paramètres de projet", - "xpack.serverlessSearch.nav.security": "Sécurité", "xpack.serverlessSearch.next": "Suivant", "xpack.serverlessSearch.optional": "Facultatif", "xpack.serverlessSearch.overview.footer.description": "Votre point de terminaison Elasticsearch est configuré et vous avez effectué quelques requêtes de base. Vous voilà prêt à approfondir les outils et les cas d'utilisation avancés.", diff --git a/x-pack/plugins/translations/translations/ja-JP.json b/x-pack/plugins/translations/translations/ja-JP.json index 5f27f5b60da13..6f0fada5b569d 100644 --- a/x-pack/plugins/translations/translations/ja-JP.json +++ b/x-pack/plugins/translations/translations/ja-JP.json @@ -37248,16 +37248,13 @@ "xpack.serverlessSearch.languages.ruby.githubLabel": "elasticsearch-serverless-ruby", "xpack.serverlessSearch.learnMore": "詳細", "xpack.serverlessSearch.nav.alerts": "アラート", - "xpack.serverlessSearch.nav.content": "コンテンツ", "xpack.serverlessSearch.nav.content.indices": "インデックス管理", "xpack.serverlessSearch.nav.content.pipelines": "パイプライン", "xpack.serverlessSearch.nav.devTools": "開発ツール", - "xpack.serverlessSearch.nav.explore": "探索", "xpack.serverlessSearch.nav.gettingStarted": "はじめて使う", "xpack.serverlessSearch.nav.mngt": "管理", "xpack.serverlessSearch.nav.performance": "パフォーマンス", "xpack.serverlessSearch.nav.projectSettings": "プロジェクト設定", - "xpack.serverlessSearch.nav.security": "セキュリティ", "xpack.serverlessSearch.next": "次へ", "xpack.serverlessSearch.optional": "オプション", "xpack.serverlessSearch.overview.footer.description": "Elasticsearchエンドポイントが設定され、いくつかの基本的なクエリが作成されました。これで、より高度なツールやユースケースを使いこなす準備が整いました。", diff --git a/x-pack/plugins/translations/translations/zh-CN.json b/x-pack/plugins/translations/translations/zh-CN.json index 7c8328a39f987..307ba7316f7fc 100644 --- a/x-pack/plugins/translations/translations/zh-CN.json +++ b/x-pack/plugins/translations/translations/zh-CN.json @@ -37244,16 +37244,13 @@ "xpack.serverlessSearch.languages.ruby.githubLabel": "elasticsearch-serverless-ruby", "xpack.serverlessSearch.learnMore": "了解详情", "xpack.serverlessSearch.nav.alerts": "告警", - "xpack.serverlessSearch.nav.content": "内容", "xpack.serverlessSearch.nav.content.indices": "索引管理", "xpack.serverlessSearch.nav.content.pipelines": "管道", "xpack.serverlessSearch.nav.devTools": "开发工具", - "xpack.serverlessSearch.nav.explore": "浏览", "xpack.serverlessSearch.nav.gettingStarted": "入门", "xpack.serverlessSearch.nav.mngt": "管理", "xpack.serverlessSearch.nav.performance": "性能", "xpack.serverlessSearch.nav.projectSettings": "项目设置", - "xpack.serverlessSearch.nav.security": "安全", "xpack.serverlessSearch.next": "下一步", "xpack.serverlessSearch.optional": "可选", "xpack.serverlessSearch.overview.footer.description": "已设置您的 Elasticsearch 终端,并且您已提出一些基本查询。现在您已准备就绪,可以更深入地了解更多高级工具和用例。", diff --git a/x-pack/plugins/triggers_actions_ui/public/application/hooks/use_get_query_delay_setting.test.tsx b/x-pack/plugins/triggers_actions_ui/public/application/hooks/use_get_query_delay_setting.test.tsx index bf792e29ed604..c4e3ec261e6e3 100644 --- a/x-pack/plugins/triggers_actions_ui/public/application/hooks/use_get_query_delay_setting.test.tsx +++ b/x-pack/plugins/triggers_actions_ui/public/application/hooks/use_get_query_delay_setting.test.tsx @@ -6,7 +6,7 @@ */ import React from 'react'; import { renderHook } from '@testing-library/react-hooks/dom'; -import { waitFor } from '@testing-library/dom'; +import { waitFor } from '@testing-library/react'; import { QueryClient, QueryClientProvider } from '@tanstack/react-query'; import { useGetQueryDelaySettings } from './use_get_query_delay_settings'; diff --git a/x-pack/plugins/triggers_actions_ui/public/application/hooks/use_load_rule_aggregations.test.tsx b/x-pack/plugins/triggers_actions_ui/public/application/hooks/use_load_rule_aggregations.test.tsx index b9f33ab40c6fc..6ea281765496f 100644 --- a/x-pack/plugins/triggers_actions_ui/public/application/hooks/use_load_rule_aggregations.test.tsx +++ b/x-pack/plugins/triggers_actions_ui/public/application/hooks/use_load_rule_aggregations.test.tsx @@ -11,7 +11,7 @@ import { RuleStatus } from '../../types'; import { useKibana } from '../../common/lib/kibana'; import { IToasts } from '@kbn/core-notifications-browser'; import { QueryClient, QueryClientProvider } from '@tanstack/react-query'; -import { waitFor } from '@testing-library/dom'; +import { waitFor } from '@testing-library/react'; jest.mock('../../common/lib/kibana'); jest.mock('../lib/rule_api/aggregate_kuery_filter', () => ({ diff --git a/x-pack/plugins/triggers_actions_ui/public/application/hooks/use_load_rules.test.tsx b/x-pack/plugins/triggers_actions_ui/public/application/hooks/use_load_rules.test.tsx index 1342746223889..1a2c07eaaa9cf 100644 --- a/x-pack/plugins/triggers_actions_ui/public/application/hooks/use_load_rules.test.tsx +++ b/x-pack/plugins/triggers_actions_ui/public/application/hooks/use_load_rules.test.tsx @@ -15,7 +15,7 @@ import { RuleStatus } from '../../types'; import { QueryClient, QueryClientProvider } from '@tanstack/react-query'; import { useKibana } from '../../common/lib/kibana'; import { IToasts } from '@kbn/core-notifications-browser'; -import { waitFor } from '@testing-library/dom'; +import { waitFor } from '@testing-library/react'; jest.mock('../../common/lib/kibana'); jest.mock('../lib/rule_api/rules_kuery_filter', () => ({ diff --git a/x-pack/plugins/triggers_actions_ui/public/application/hooks/use_load_tags_query.test.tsx b/x-pack/plugins/triggers_actions_ui/public/application/hooks/use_load_tags_query.test.tsx index 7e36b5e4290ad..bb2dab67c0d4e 100644 --- a/x-pack/plugins/triggers_actions_ui/public/application/hooks/use_load_tags_query.test.tsx +++ b/x-pack/plugins/triggers_actions_ui/public/application/hooks/use_load_tags_query.test.tsx @@ -10,7 +10,7 @@ import { useLoadTagsQuery } from './use_load_tags_query'; import { QueryClient, QueryClientProvider } from '@tanstack/react-query'; import { useKibana } from '../../common/lib/kibana'; import { IToasts } from '@kbn/core-notifications-browser'; -import { waitFor } from '@testing-library/dom'; +import { waitFor } from '@testing-library/react'; const MOCK_TAGS = ['a', 'b', 'c']; diff --git a/x-pack/plugins/triggers_actions_ui/public/application/hooks/use_update_rules_settings.test.tsx b/x-pack/plugins/triggers_actions_ui/public/application/hooks/use_update_rules_settings.test.tsx index 6a36a32ed2522..e431a4c2cf7aa 100644 --- a/x-pack/plugins/triggers_actions_ui/public/application/hooks/use_update_rules_settings.test.tsx +++ b/x-pack/plugins/triggers_actions_ui/public/application/hooks/use_update_rules_settings.test.tsx @@ -7,7 +7,7 @@ import React from 'react'; import { QueryClient, QueryClientProvider } from '@tanstack/react-query'; import { act, renderHook } from '@testing-library/react-hooks/dom'; -import { waitFor } from '@testing-library/dom'; +import { waitFor } from '@testing-library/react'; import { useUpdateRuleSettings } from './use_update_rules_settings'; const mockAddDanger = jest.fn(); diff --git a/x-pack/plugins/triggers_actions_ui/public/application/sections/action_connector_form/connector_form.test.tsx b/x-pack/plugins/triggers_actions_ui/public/application/sections/action_connector_form/connector_form.test.tsx index 95e7b0c85ab55..cf12e2ce38af4 100644 --- a/x-pack/plugins/triggers_actions_ui/public/application/sections/action_connector_form/connector_form.test.tsx +++ b/x-pack/plugins/triggers_actions_ui/public/application/sections/action_connector_form/connector_form.test.tsx @@ -9,7 +9,7 @@ import React, { lazy } from 'react'; import { ConnectorForm } from './connector_form'; import { actionTypeRegistryMock } from '../../action_type_registry.mock'; import userEvent from '@testing-library/user-event'; -import { waitFor } from '@testing-library/dom'; +import { waitFor } from '@testing-library/react'; import { act } from '@testing-library/react'; import { AppMockRenderer, createAppMockRenderer } from '../test_utils'; diff --git a/x-pack/plugins/triggers_actions_ui/public/application/sections/action_connector_form/connector_form_fields.test.tsx b/x-pack/plugins/triggers_actions_ui/public/application/sections/action_connector_form/connector_form_fields.test.tsx index c2a6a86bb446b..45937cee8b22a 100644 --- a/x-pack/plugins/triggers_actions_ui/public/application/sections/action_connector_form/connector_form_fields.test.tsx +++ b/x-pack/plugins/triggers_actions_ui/public/application/sections/action_connector_form/connector_form_fields.test.tsx @@ -10,7 +10,7 @@ import { coreMock } from '@kbn/core/public/mocks'; import { FormTestProvider } from '../../components/test_utils'; import { ConnectorFormFields } from './connector_form_fields'; import { actionTypeRegistryMock } from '../../action_type_registry.mock'; -import { waitFor } from '@testing-library/dom'; +import { waitFor } from '@testing-library/react'; import { AppMockRenderer, createAppMockRenderer } from '../test_utils'; describe('ConnectorFormFields', () => { diff --git a/x-pack/plugins/triggers_actions_ui/public/application/sections/action_connector_form/create_connector_flyout/index.test.tsx b/x-pack/plugins/triggers_actions_ui/public/application/sections/action_connector_form/create_connector_flyout/index.test.tsx index 9cc4603025ff3..554fb9aff3c30 100644 --- a/x-pack/plugins/triggers_actions_ui/public/application/sections/action_connector_form/create_connector_flyout/index.test.tsx +++ b/x-pack/plugins/triggers_actions_ui/public/application/sections/action_connector_form/create_connector_flyout/index.test.tsx @@ -9,8 +9,7 @@ import React, { lazy } from 'react'; import { actionTypeRegistryMock } from '../../../action_type_registry.mock'; import userEvent from '@testing-library/user-event'; -import { waitFor } from '@testing-library/dom'; -import { act } from '@testing-library/react'; +import { waitFor, act } from '@testing-library/react'; import CreateConnectorFlyout from '.'; import { betaBadgeProps } from '../beta_badge_props'; import { AppMockRenderer, createAppMockRenderer } from '../../test_utils'; diff --git a/x-pack/plugins/triggers_actions_ui/public/application/sections/action_connector_form/edit_connector_flyout/index.test.tsx b/x-pack/plugins/triggers_actions_ui/public/application/sections/action_connector_form/edit_connector_flyout/index.test.tsx index e687189ed0205..a108de1dc6f6c 100644 --- a/x-pack/plugins/triggers_actions_ui/public/application/sections/action_connector_form/edit_connector_flyout/index.test.tsx +++ b/x-pack/plugins/triggers_actions_ui/public/application/sections/action_connector_form/edit_connector_flyout/index.test.tsx @@ -9,8 +9,7 @@ import React, { lazy } from 'react'; import { actionTypeRegistryMock } from '../../../action_type_registry.mock'; import userEvent from '@testing-library/user-event'; -import { waitFor } from '@testing-library/dom'; -import { act } from '@testing-library/react'; +import { waitFor, act } from '@testing-library/react'; import EditConnectorFlyout from '.'; import { ActionConnector, EditConnectorTabs, GenericValidationResult } from '../../../../types'; import { betaBadgeProps } from '../beta_badge_props'; diff --git a/x-pack/plugins/triggers_actions_ui/public/application/sections/alerts_table/hooks/use_bulk_get_cases.test.tsx b/x-pack/plugins/triggers_actions_ui/public/application/sections/alerts_table/hooks/use_bulk_get_cases.test.tsx index 5f027e9b57fd0..945028df8118f 100644 --- a/x-pack/plugins/triggers_actions_ui/public/application/sections/alerts_table/hooks/use_bulk_get_cases.test.tsx +++ b/x-pack/plugins/triggers_actions_ui/public/application/sections/alerts_table/hooks/use_bulk_get_cases.test.tsx @@ -7,7 +7,7 @@ import { renderHook } from '@testing-library/react-hooks'; import * as api from './apis/bulk_get_cases'; -import { waitFor } from '@testing-library/dom'; +import { waitFor } from '@testing-library/react'; import { useKibana } from '../../../../common/lib/kibana'; import { useBulkGetCases } from './use_bulk_get_cases'; import { AppMockRenderer, createAppMockRenderer } from '../../test_utils'; diff --git a/x-pack/plugins/triggers_actions_ui/public/application/sections/alerts_table/hooks/use_bulk_get_maintenance_windows.test.ts b/x-pack/plugins/triggers_actions_ui/public/application/sections/alerts_table/hooks/use_bulk_get_maintenance_windows.test.ts index e5b45a25b5dea..b46424c286c00 100644 --- a/x-pack/plugins/triggers_actions_ui/public/application/sections/alerts_table/hooks/use_bulk_get_maintenance_windows.test.ts +++ b/x-pack/plugins/triggers_actions_ui/public/application/sections/alerts_table/hooks/use_bulk_get_maintenance_windows.test.ts @@ -6,7 +6,7 @@ */ import { renderHook } from '@testing-library/react-hooks'; -import { waitFor } from '@testing-library/dom'; +import { waitFor } from '@testing-library/react'; import { MaintenanceWindowStatus } from '@kbn/alerting-plugin/common'; import * as api from './apis/bulk_get_maintenance_windows'; import { coreMock } from '@kbn/core/public/mocks'; diff --git a/x-pack/plugins/uptime/kibana.jsonc b/x-pack/plugins/uptime/kibana.jsonc index df0b2e13839cf..c07d0dc342a74 100644 --- a/x-pack/plugins/uptime/kibana.jsonc +++ b/x-pack/plugins/uptime/kibana.jsonc @@ -1,7 +1,7 @@ { "type": "plugin", "id": "@kbn/uptime-plugin", - "owner": "@elastic/uptime", + "owner": "@elastic/obs-ux-infra_services-team", "description": "This plugin visualizes data from Heartbeat, and integrates with other Observability solutions.", "plugin": { "id": "uptime", diff --git a/x-pack/plugins/uptime/public/legacy_uptime/components/common/uptime_date_picker.test.tsx b/x-pack/plugins/uptime/public/legacy_uptime/components/common/uptime_date_picker.test.tsx index 1510fe28f1721..66fd680d3fdfe 100644 --- a/x-pack/plugins/uptime/public/legacy_uptime/components/common/uptime_date_picker.test.tsx +++ b/x-pack/plugins/uptime/public/legacy_uptime/components/common/uptime_date_picker.test.tsx @@ -10,7 +10,7 @@ import { UptimeDatePicker } from './uptime_date_picker'; import { startPlugins } from '../../lib/__mocks__/uptime_plugin_start_mock'; import { createMemoryHistory } from 'history'; import { render } from '../../lib/helper/rtl_helpers'; -import { fireEvent } from '@testing-library/dom'; +import { fireEvent } from '@testing-library/react'; describe('UptimeDatePicker component', () => { jest.setTimeout(10_000); diff --git a/x-pack/plugins/uptime/public/legacy_uptime/components/monitor/synthetics/waterfall/components/waterfall.test.tsx b/x-pack/plugins/uptime/public/legacy_uptime/components/monitor/synthetics/waterfall/components/waterfall.test.tsx index 28e82930f3341..7761fe4206fda 100644 --- a/x-pack/plugins/uptime/public/legacy_uptime/components/monitor/synthetics/waterfall/components/waterfall.test.tsx +++ b/x-pack/plugins/uptime/public/legacy_uptime/components/monitor/synthetics/waterfall/components/waterfall.test.tsx @@ -11,7 +11,7 @@ import { renderLegendItem } from '../../step_detail/waterfall/waterfall_chart_wr import { render } from '../../../../../lib/helper/rtl_helpers'; import 'jest-canvas-mock'; -import { waitFor } from '@testing-library/dom'; +import { waitFor } from '@testing-library/react'; describe('waterfall', () => { it('sets the correct height in case of full height', () => { diff --git a/x-pack/plugins/uptime/public/legacy_uptime/components/monitor/synthetics/waterfall/components/waterfall_marker_icon.test.tsx b/x-pack/plugins/uptime/public/legacy_uptime/components/monitor/synthetics/waterfall/components/waterfall_marker_icon.test.tsx index 4241a7238ecd6..4bfe9d2dccfdd 100644 --- a/x-pack/plugins/uptime/public/legacy_uptime/components/monitor/synthetics/waterfall/components/waterfall_marker_icon.test.tsx +++ b/x-pack/plugins/uptime/public/legacy_uptime/components/monitor/synthetics/waterfall/components/waterfall_marker_icon.test.tsx @@ -6,7 +6,7 @@ */ import React from 'react'; -import { fireEvent, waitFor } from '@testing-library/dom'; +import { fireEvent, waitFor } from '@testing-library/react'; import { render } from '../../../../../lib/helper/rtl_helpers'; import { WaterfallMarkerIcon } from './waterfall_marker_icon'; import { TestWrapper } from './waterfall_marker_test_helper'; diff --git a/x-pack/plugins/uptime/public/legacy_uptime/components/overview/alerts/monitor_status_alert/alert_monitor_status.test.tsx b/x-pack/plugins/uptime/public/legacy_uptime/components/overview/alerts/monitor_status_alert/alert_monitor_status.test.tsx index 6dbef12159a18..c547b66748ffc 100644 --- a/x-pack/plugins/uptime/public/legacy_uptime/components/overview/alerts/monitor_status_alert/alert_monitor_status.test.tsx +++ b/x-pack/plugins/uptime/public/legacy_uptime/components/overview/alerts/monitor_status_alert/alert_monitor_status.test.tsx @@ -6,7 +6,7 @@ */ import React from 'react'; -import { screen } from '@testing-library/dom'; +import { screen } from '@testing-library/react'; import { AlertMonitorStatusComponent, AlertMonitorStatusProps, diff --git a/x-pack/plugins/uptime/public/legacy_uptime/components/overview/monitor_list/columns/define_connectors.test.tsx b/x-pack/plugins/uptime/public/legacy_uptime/components/overview/monitor_list/columns/define_connectors.test.tsx index 29f0dd189594c..3774e94e190b8 100644 --- a/x-pack/plugins/uptime/public/legacy_uptime/components/overview/monitor_list/columns/define_connectors.test.tsx +++ b/x-pack/plugins/uptime/public/legacy_uptime/components/overview/monitor_list/columns/define_connectors.test.tsx @@ -7,8 +7,7 @@ import React from 'react'; import { DefineAlertConnectors } from './define_connectors'; -import { screen } from '@testing-library/react'; -import { fireEvent } from '@testing-library/dom'; +import { screen, fireEvent } from '@testing-library/react'; import { ENABLE_STATUS_ALERT } from './translations'; import { render } from '../../../../lib/helper/rtl_helpers'; diff --git a/x-pack/plugins/uptime/public/legacy_uptime/components/overview/monitor_list/columns/enable_alert.test.tsx b/x-pack/plugins/uptime/public/legacy_uptime/components/overview/monitor_list/columns/enable_alert.test.tsx index 416dd8e963e9b..2f18c3e89f147 100644 --- a/x-pack/plugins/uptime/public/legacy_uptime/components/overview/monitor_list/columns/enable_alert.test.tsx +++ b/x-pack/plugins/uptime/public/legacy_uptime/components/overview/monitor_list/columns/enable_alert.test.tsx @@ -7,7 +7,7 @@ import React from 'react'; import { EnableMonitorAlert } from './enable_alert'; -import { fireEvent } from '@testing-library/dom'; +import { fireEvent } from '@testing-library/react'; import { DYNAMIC_SETTINGS_DEFAULTS } from '../../../../../../common/constants'; import { makePing } from '../../../../../../common/runtime_types/ping'; diff --git a/x-pack/plugins/uptime/public/legacy_uptime/components/synthetics/check_steps/use_expanded_row.test.tsx b/x-pack/plugins/uptime/public/legacy_uptime/components/synthetics/check_steps/use_expanded_row.test.tsx index f79a93eee53e4..a139abe5d86a0 100644 --- a/x-pack/plugins/uptime/public/legacy_uptime/components/synthetics/check_steps/use_expanded_row.test.tsx +++ b/x-pack/plugins/uptime/public/legacy_uptime/components/synthetics/check_steps/use_expanded_row.test.tsx @@ -8,7 +8,7 @@ import React from 'react'; import ReactRouterDom from 'react-router-dom'; import { Route } from '@kbn/shared-ux-router'; -import { fireEvent, screen } from '@testing-library/dom'; +import { fireEvent, screen } from '@testing-library/react'; import { renderHook, act as hooksAct } from '@testing-library/react-hooks'; import { createMemoryHistory } from 'history'; import { EuiButtonIcon } from '@elastic/eui'; diff --git a/x-pack/plugins/uptime/public/legacy_uptime/lib/helper/rtl_helpers.tsx b/x-pack/plugins/uptime/public/legacy_uptime/lib/helper/rtl_helpers.tsx index b2f96c4bac8a3..0b23c089385d7 100644 --- a/x-pack/plugins/uptime/public/legacy_uptime/lib/helper/rtl_helpers.tsx +++ b/x-pack/plugins/uptime/public/legacy_uptime/lib/helper/rtl_helpers.tsx @@ -12,6 +12,7 @@ import { render as reactTestLibRender, MatcherFunction, RenderOptions, + configure, } from '@testing-library/react'; import { Router } from '@kbn/shared-ux-router'; import { Route } from '@kbn/shared-ux-router'; @@ -21,8 +22,6 @@ import { createMemoryHistory, History } from 'history'; import { CoreStart } from '@kbn/core/public'; import { I18nProvider } from '@kbn/i18n-react'; import { coreMock } from '@kbn/core/public/mocks'; -// eslint-disable-next-line import/no-extraneous-dependencies -import { configure } from '@testing-library/dom'; import { EuiThemeProvider } from '@kbn/kibana-react-plugin/common'; import { IStorageWrapper } from '@kbn/kibana-utils-plugin/public'; import { KibanaContextProvider, KibanaServices } from '@kbn/kibana-react-plugin/public'; diff --git a/x-pack/plugins/uptime/public/legacy_uptime/pages/settings.test.tsx b/x-pack/plugins/uptime/public/legacy_uptime/pages/settings.test.tsx index 5c8fb95448fca..a8144f540a03e 100644 --- a/x-pack/plugins/uptime/public/legacy_uptime/pages/settings.test.tsx +++ b/x-pack/plugins/uptime/public/legacy_uptime/pages/settings.test.tsx @@ -8,7 +8,7 @@ import React from 'react'; import { isValidCertVal, SettingsPage } from './settings'; import { render } from '../lib/helper/rtl_helpers'; -import { fireEvent, waitFor } from '@testing-library/dom'; +import { fireEvent, waitFor } from '@testing-library/react'; import * as alertApi from '../state/api/alerts'; import { DYNAMIC_SETTINGS_DEFAULTS } from '../../../common/constants'; diff --git a/x-pack/plugins/ux/kibana.jsonc b/x-pack/plugins/ux/kibana.jsonc index af8d92f151786..e35cddbabbba6 100644 --- a/x-pack/plugins/ux/kibana.jsonc +++ b/x-pack/plugins/ux/kibana.jsonc @@ -1,7 +1,7 @@ { "type": "plugin", "id": "@kbn/ux-plugin", - "owner": "@elastic/uptime", + "owner": "@elastic/obs-ux-infra_services-team", "plugin": { "id": "ux", "server": true, diff --git a/x-pack/test/api_integration/apis/metrics_ui/constants.ts b/x-pack/test/api_integration/apis/metrics_ui/constants.ts index 7fd25f09875b4..13fd1acf7b199 100644 --- a/x-pack/test/api_integration/apis/metrics_ui/constants.ts +++ b/x-pack/test/api_integration/apis/metrics_ui/constants.ts @@ -40,7 +40,7 @@ export const DATES = { }, logs_and_metrics_with_aws: { min: 1564083185000, - max: 1564083493080, + max: 1564083705100, }, }, 'alert-test-data': { diff --git a/x-pack/test/security_solution_cypress/cypress/e2e/detection_response/rule_management/rule_actions/bulk_actions/bulk_edit_rules_actions.cy.ts b/x-pack/test/security_solution_cypress/cypress/e2e/detection_response/rule_management/rule_actions/bulk_actions/bulk_edit_rules_actions.cy.ts index d543843641b78..ac6c723dbc0c6 100644 --- a/x-pack/test/security_solution_cypress/cypress/e2e/detection_response/rule_management/rule_actions/bulk_actions/bulk_edit_rules_actions.cy.ts +++ b/x-pack/test/security_solution_cypress/cypress/e2e/detection_response/rule_management/rule_actions/bulk_actions/bulk_edit_rules_actions.cy.ts @@ -76,7 +76,7 @@ const expectedSlackMessage = 'Slack action test message'; describe( 'Detection rules, bulk edit of rule actions', - { tags: ['@ess', '@serverless', '@brokenInServerlessQA'] }, + { tags: ['@ess', '@serverless', '@brokenInServerless', '@brokenInServerlessQA'] }, () => { beforeEach(() => { login(); diff --git a/x-pack/test/security_solution_cypress/package.json b/x-pack/test/security_solution_cypress/package.json index 67125c9c55daa..0e34d7867d37a 100644 --- a/x-pack/test/security_solution_cypress/package.json +++ b/x-pack/test/security_solution_cypress/package.json @@ -7,7 +7,7 @@ "scripts": { "cypress": "NODE_OPTIONS=--openssl-legacy-provider ../../../node_modules/.bin/cypress", "cypress:open:ess": "TZ=UTC NODE_OPTIONS=--openssl-legacy-provider node ../../plugins/security_solution/scripts/start_cypress_parallel open --spec './cypress/e2e/**/*.cy.ts' --config-file ../../test/security_solution_cypress/cypress/cypress.config.ts --ftr-config-file ../../test/security_solution_cypress/cli_config", - "cypress:run:ess": "yarn cypress:ess --spec './cypress/e2e/exceptions/shared_exception_lists_management/**/*.cy.ts'", + "cypress:run:ess": "yarn cypress:ess --spec './cypress/e2e/!(investigations|explore)/**/*.cy.ts'", "cypress:run:cases:ess": "yarn cypress:ess --spec './cypress/e2e/explore/cases/*.cy.ts'", "cypress:ess": "TZ=UTC NODE_OPTIONS=--openssl-legacy-provider node ../../plugins/security_solution/scripts/start_cypress_parallel run --config-file ../../test/security_solution_cypress/cypress/cypress_ci.config.ts --ftr-config-file ../../test/security_solution_cypress/cli_config", "cypress:run:respops:ess": "yarn cypress:ess --spec './cypress/e2e/(detection_response|exceptions)/**/*.cy.ts'", @@ -21,7 +21,7 @@ "cypress:cloud:serverless": "TZ=UTC NODE_OPTIONS=--openssl-legacy-provider NODE_TLS_REJECT_UNAUTHORIZED=0 ../../../node_modules/.bin/cypress", "cypress:open:cloud:serverless": "yarn cypress:cloud:serverless open --config-file ./cypress/cypress_serverless.config.ts --env CLOUD_SERVERLESS=true", "cypress:open:serverless": "yarn cypress:serverless open --config-file ../../test/security_solution_cypress/cypress/cypress_serverless.config.ts --spec './cypress/e2e/**/*.cy.ts'", - "cypress:run:serverless": "yarn cypress:serverless --spec './cypress/e2e/exceptions/shared_exception_lists_management/**/*.cy.ts'", + "cypress:run:serverless": "yarn cypress:serverless --spec './cypress/e2e/!(investigations|explore)/**/*.cy.ts'", "cypress:run:cloud:serverless": "yarn cypress:cloud:serverless run --config-file ./cypress/cypress_ci_serverless.config.ts --env CLOUD_SERVERLESS=true", "cypress:investigations:run:serverless": "yarn cypress:serverless --spec './cypress/e2e/investigations/**/*.cy.ts'", "cypress:explore:run:serverless": "yarn cypress:serverless --spec './cypress/e2e/explore/**/*.cy.ts'", diff --git a/x-pack/test_serverless/functional/test_suites/search/navigation.ts b/x-pack/test_serverless/functional/test_suites/search/navigation.ts index 03f229f21b47a..8796dcfe93773 100644 --- a/x-pack/test_serverless/functional/test_suites/search/navigation.ts +++ b/x-pack/test_serverless/functional/test_suites/search/navigation.ts @@ -72,20 +72,16 @@ export default function ({ getPageObject, getService }: FtrProviderContext) { it("management apps from the sidenav hide the 'stack management' root from the breadcrumbs", async () => { await svlCommonNavigation.sidenav.clickLink({ deepLinkId: 'management:triggersActions' }); - await svlCommonNavigation.breadcrumbs.expectBreadcrumbTexts(['Explore', 'Alerts', 'Rules']); + await svlCommonNavigation.breadcrumbs.expectBreadcrumbTexts(['Alerts', 'Rules']); await svlCommonNavigation.sidenav.clickLink({ deepLinkId: 'management:index_management' }); - await svlCommonNavigation.breadcrumbs.expectBreadcrumbTexts([ - 'Content', - 'Index Management', - 'Indices', - ]); + await svlCommonNavigation.breadcrumbs.expectBreadcrumbTexts(['Index Management', 'Indices']); await svlCommonNavigation.sidenav.clickLink({ deepLinkId: 'management:ingest_pipelines' }); - await svlCommonNavigation.breadcrumbs.expectBreadcrumbTexts(['Content', 'Ingest Pipelines']); + await svlCommonNavigation.breadcrumbs.expectBreadcrumbTexts(['Ingest Pipelines']); await svlCommonNavigation.sidenav.clickLink({ deepLinkId: 'management:api_keys' }); - await svlCommonNavigation.breadcrumbs.expectBreadcrumbTexts(['Security', 'API keys']); + await svlCommonNavigation.breadcrumbs.expectBreadcrumbTexts(['API keys']); }); it('navigate management', async () => { diff --git a/yarn.lock b/yarn.lock index 0d11dd72a0359..813e52bcf4912 100644 --- a/yarn.lock +++ b/yarn.lock @@ -8251,7 +8251,7 @@ resolved "https://registry.yarnpkg.com/@testim/chrome-version/-/chrome-version-1.1.3.tgz#fbb68696899d7b8c1b9b891eded9c04fe2cd5529" integrity sha512-g697J3WxV/Zytemz8aTuKjTGYtta9+02kva3C1xc7KXB8GdbfE1akGJIsZLyY/FSh2QrnE+fiB7vmWU3XNcb6A== -"@testing-library/dom@^8.0.0", "@testing-library/dom@^8.19.0": +"@testing-library/dom@^8.0.0": version "8.19.0" resolved "https://registry.yarnpkg.com/@testing-library/dom/-/dom-8.19.0.tgz#bd3f83c217ebac16694329e413d9ad5fdcfd785f" integrity sha512-6YWYPPpxG3e/xOo6HIWwB/58HukkwIVTOaZ0VwdMVjhRUX/01E4FtQbck9GazOOj7MXHc5RBzMrU86iBJHbI+A== @@ -20473,10 +20473,10 @@ kdbush@^4.0.2: resolved "https://registry.yarnpkg.com/kdbush/-/kdbush-4.0.2.tgz#2f7b7246328b4657dd122b6c7f025fbc2c868e39" integrity sha512-WbCVYJ27Sz8zi9Q7Q0xHC+05iwkm3Znipc2XTlrnJbsHMYktW4hPhXUE8Ys1engBrvffoSCqbil1JQAa7clRpA== -kea@^2.4.2: - version "2.4.2" - resolved "https://registry.yarnpkg.com/kea/-/kea-2.4.2.tgz#53af42702f2c8962422e456e5dd943391bad26e9" - integrity sha512-cdGds/gsJsbo/KbVAMk5/tTr229eDibVT1wmPPxPO/10zYb8GFoP3udBIQb+Hop5qGEu2wIHVdXwJvXqSS8JAg== +kea@^2.6.0: + version "2.6.0" + resolved "https://registry.yarnpkg.com/kea/-/kea-2.6.0.tgz#774a82188e0fb52cdb18b72843a875ee857f3807" + integrity sha512-+yaLyZx8h2v96aL01XIRZjqA8Qk4fIUziznSKnkjDItUU8YnH75xER6+vMHT5EHC3MJeSScxIx5UuqZl30DBdg== keyv@^3.0.0: version "3.0.0"