Skip to content

Commit

Permalink
Sustainable Kibana Architecture: Move modules owned by `@elastic/secu…
Browse files Browse the repository at this point in the history
…rity-detections-response` (elastic#202847)

## Summary

This PR aims at relocating some of the Kibana modules (plugins and
packages) into a new folder structure, according to the _Sustainable
Kibana Architecture_ initiative.

> [!IMPORTANT]
> * We kindly ask you to:
> * Manually fix the errors in the error section below (if there are
any).
> * Search for the `packages[\/\\]` and `plugins[\/\\]` patterns in the
source code (Babel and Eslint config files), and update them
appropriately.
> * Manually review
`.buildkite/scripts/pipelines/pull_request/pipeline.ts` to ensure that
any CI pipeline customizations continue to be correctly applied after
the changed path names
> * Review all of the updated files, specially the `.ts` and `.js` files
listed in the sections below, as some of them contain relative paths
that have been updated.
> * Think of potential impact of the move, including tooling and
configuration files that can be pointing to the relocated modules. E.g.:
>     * customised eslint rules
>     * docs pointing to source code

> [!NOTE]
> * This PR has been auto-generated.
> * Any manual contributions will be lost if the 'relocate' script is
re-run.
> * Try to obtain the missing reviews / approvals before applying manual
fixes, and/or keep your changes in a .patch / git stash.
> * Please use
[#sustainable_kibana_architecture](https://elastic.slack.com/archives/C07TCKTA22E)
Slack channel for feedback.

Are you trying to rebase this PR to solve merge conflicts? Please follow
the steps describe
[here](https://elastic.slack.com/archives/C07TCKTA22E/p1734019532879269?thread_ts=1734019339.935419&cid=C07TCKTA22E).

#### 1 packages(s) are going to be relocated:

| Id | Target folder |
| -- | ------------- |
| `@kbn/rule-data-utils` |
`src/platform/packages/shared/kbn-rule-data-utils` |


<details >
<summary>Updated references</summary>

```
./package.json
./packages/kbn-repo-packages/package-map.json
./packages/kbn-ts-projects/config-paths.json
./src/platform/packages/shared/kbn-rule-data-utils/jest.config.js
./src/platform/plugins/shared/discover/tsconfig.type_check.json
./tsconfig.base.json
./tsconfig.base.type_check.json
./tsconfig.refs.json
./x-pack/examples/triggers_actions_ui_example/tsconfig.type_check.json
./x-pack/packages/observability/alert_details/tsconfig.type_check.json
./x-pack/packages/observability/alerting_test_data/tsconfig.type_check.json
./x-pack/platform/plugins/private/monitoring/tsconfig.type_check.json
./x-pack/plugins/alerting/tsconfig.type_check.json
./x-pack/plugins/cases/tsconfig.type_check.json
./x-pack/plugins/ml/tsconfig.type_check.json
./x-pack/plugins/observability_solution/apm/tsconfig.type_check.json
./x-pack/plugins/observability_solution/infra/tsconfig.type_check.json
./x-pack/plugins/observability_solution/investigate_app/tsconfig.type_check.json
./x-pack/plugins/observability_solution/observability/tsconfig.type_check.json
./x-pack/plugins/observability_solution/observability_logs_explorer/tsconfig.type_check.json
./x-pack/plugins/observability_solution/observability_shared/tsconfig.type_check.json
./x-pack/plugins/observability_solution/slo/tsconfig.type_check.json
./x-pack/plugins/observability_solution/synthetics/tsconfig.type_check.json
./x-pack/plugins/observability_solution/uptime/tsconfig.type_check.json
./x-pack/plugins/rule_registry/tsconfig.type_check.json
./x-pack/plugins/stack_alerts/tsconfig.type_check.json
./x-pack/plugins/transform/tsconfig.type_check.json
./x-pack/plugins/triggers_actions_ui/tsconfig.type_check.json
./x-pack/solutions/security/plugins/timelines/tsconfig.type_check.json
./x-pack/test/alerting_api_integration/common/plugins/alerts/tsconfig.type_check.json
./x-pack/test/security_solution_api_integration/tsconfig.type_check.json
./x-pack/test/tsconfig.type_check.json
./x-pack/test_serverless/tsconfig.type_check.json
./yarn.lock
.github/CODEOWNERS
```

</details><details >
<summary>Updated relative paths</summary>

```
src/platform/packages/shared/kbn-rule-data-utils/jest.config.js:12
src/platform/packages/shared/kbn-rule-data-utils/tsconfig.json:2
src/platform/packages/shared/kbn-rule-data-utils/tsconfig.type_check.json:2
```

</details>

Co-authored-by: Marshall Main <[email protected]>
  • Loading branch information
2 people authored and JoseLuisGJ committed Dec 19, 2024
1 parent cb17c55 commit 09fbf2e
Show file tree
Hide file tree
Showing 22 changed files with 9 additions and 9 deletions.
2 changes: 1 addition & 1 deletion .buildkite/scripts/pipelines/pull_request/pipeline.ts
Original file line number Diff line number Diff line change
Expand Up @@ -302,7 +302,7 @@ const getPipeline = (filename: string, removeSteps = true) => {
/^packages\/kbn-grouping/,
/^packages\/kbn-resizable-layout/,
/^packages\/kbn-rison/,
/^packages\/kbn-rule-data-utils/,
/^src\/platform\/packages\/shared\/kbn-rule-data-utils/,
/^packages\/kbn-safer-lodash-set/,
/^packages\/kbn-search-types/,
/^packages\/kbn-securitysolution-.*/,
Expand Down
2 changes: 1 addition & 1 deletion .github/CODEOWNERS
Validating CODEOWNERS rules …
Original file line number Diff line number Diff line change
Expand Up @@ -436,7 +436,6 @@ packages/kbn-rison @elastic/kibana-operations
packages/kbn-router-to-openapispec @elastic/kibana-core
packages/kbn-router-utils @elastic/obs-ux-logs-team
packages/kbn-rrule @elastic/response-ops
packages/kbn-rule-data-utils @elastic/security-detections-response @elastic/response-ops @elastic/obs-ux-management-team
packages/kbn-safer-lodash-set @elastic/kibana-security
packages/kbn-saved-objects-settings @elastic/appex-sharedux
packages/kbn-saved-search-component @elastic/obs-ux-logs-team
Expand Down Expand Up @@ -595,6 +594,7 @@ src/platform/packages/shared/kbn-management/settings/types @elastic/kibana-manag
src/platform/packages/shared/kbn-management/settings/utilities @elastic/kibana-management
src/platform/packages/shared/kbn-openapi-common @elastic/security-detection-rule-management
src/platform/packages/shared/kbn-osquery-io-ts-types @elastic/security-asset-management
src/platform/packages/shared/kbn-rule-data-utils @elastic/security-detections-response @elastic/response-ops @elastic/obs-ux-management-team
src/platform/packages/shared/kbn-securitysolution-ecs @elastic/security-threat-hunting-explore
src/platform/packages/shared/kbn-securitysolution-es-utils @elastic/security-detection-engine
src/platform/packages/shared/kbn-securitysolution-io-ts-types @elastic/security-detection-engine
Expand Down
2 changes: 1 addition & 1 deletion package.json
Original file line number Diff line number Diff line change
Expand Up @@ -773,7 +773,7 @@
"@kbn/router-utils": "link:packages/kbn-router-utils",
"@kbn/routing-example-plugin": "link:examples/routing_example",
"@kbn/rrule": "link:packages/kbn-rrule",
"@kbn/rule-data-utils": "link:packages/kbn-rule-data-utils",
"@kbn/rule-data-utils": "link:src/platform/packages/shared/kbn-rule-data-utils",
"@kbn/rule-registry-plugin": "link:x-pack/plugins/rule_registry",
"@kbn/runtime-fields-plugin": "link:x-pack/platform/plugins/private/runtime_fields",
"@kbn/safer-lodash-set": "link:packages/kbn-safer-lodash-set",
Expand Down
File renamed without changes.
Original file line number Diff line number Diff line change
Expand Up @@ -9,6 +9,6 @@

module.exports = {
preset: '@kbn/test',
rootDir: '../..',
roots: ['<rootDir>/packages/kbn-rule-data-utils'],
rootDir: '../../../../..',
roots: ['<rootDir>/src/platform/packages/shared/kbn-rule-data-utils'],
};
File renamed without changes.
File renamed without changes.
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
{
"extends": "../../tsconfig.base.json",
"extends": "../../../../../tsconfig.base.json",
"compilerOptions": {
"outDir": "target/types",
"types": [
Expand Down
4 changes: 2 additions & 2 deletions tsconfig.base.json
Original file line number Diff line number Diff line change
Expand Up @@ -1516,8 +1516,8 @@
"@kbn/routing-example-plugin/*": ["examples/routing_example/*"],
"@kbn/rrule": ["packages/kbn-rrule"],
"@kbn/rrule/*": ["packages/kbn-rrule/*"],
"@kbn/rule-data-utils": ["packages/kbn-rule-data-utils"],
"@kbn/rule-data-utils/*": ["packages/kbn-rule-data-utils/*"],
"@kbn/rule-data-utils": ["src/platform/packages/shared/kbn-rule-data-utils"],
"@kbn/rule-data-utils/*": ["src/platform/packages/shared/kbn-rule-data-utils/*"],
"@kbn/rule-registry-plugin": ["x-pack/plugins/rule_registry"],
"@kbn/rule-registry-plugin/*": ["x-pack/plugins/rule_registry/*"],
"@kbn/runtime-fields-plugin": ["x-pack/platform/plugins/private/runtime_fields"],
Expand Down
2 changes: 1 addition & 1 deletion yarn.lock
Original file line number Diff line number Diff line change
Expand Up @@ -6849,7 +6849,7 @@
version "0.0.0"
uid ""

"@kbn/rule-data-utils@link:packages/kbn-rule-data-utils":
"@kbn/rule-data-utils@link:src/platform/packages/shared/kbn-rule-data-utils":
version "0.0.0"
uid ""

Expand Down

0 comments on commit 09fbf2e

Please sign in to comment.