## Summary Addressees https://github.com/elastic/kibana/issues/83910 by removing the elastic legacy client from: * `lists` plugin * `security_solution` plugin * `kbn-securitysolution-es-utils` package Removes found dead code in `security_solution` plugin: * `server/lib/configuration/inmemory_configuration_adapter.ts` * `server/lib/detection_engine/privileges/read_privileges.ts` * `server/lib/configuration/index.ts` * `server/lib/configuration/adapter_types.ts` * `server/lib/compose/kibana.ts` * `server/lib/ecs_fields/extend_map.test.ts` * `server/lib/ecs_fields/extend_map.ts` * `server/lib/index_fields/elasticsearch_adapter.ts` * `server/lib/index_fields/index.ts` * `server/lib/index_fields/mock.ts` * `server/lib/index_fields/types.ts` * `server/lib/source_status/elasticsearch_adapter.ts` * `server/lib/source_status/index.ts` * `server/lib/source_status/query.dsl.ts` * `server/lib/source_status/types.ts` * `server/lib/sources/configuration.test.ts` * `server/lib/sources/configuration.ts` * `server/lib/sources/index.ts` * `server/lib/sources/types.ts` Removes dead code in `lists` plugin: * `server/schemas/common/get_call_cluster.mock.ts` * `server/lib/ecs_fields/index.ts` * `server/lib/framework/kibana_framework_adapter.ts` Removes dead types from `security_solution` plugin: * `server/lib/framework/types.ts` * `server/lib/types.ts` Removes dead functions from `security_solution` plugin: * `server/utils/build_query/calculate_timeseries_interval.ts` * `server/utils/runtime_types.ts` ### What to check as a reviewer * Ensure that there is no left over words of `legacy` such as `legacy.something` * Ensure there are no more `callAsCurrentUser` since that is all dead and gone * Ensure anywhere you see `esClient.someThing` it returns the `.body` at the end or destructors it as in `{ body } = esClient.someThing` ### Risk Matrix | Risk | Probability | Severity | Mitigation/Notes | |---------------------------|-------------|----------|-------------------------| | Telemetry might stop working or have invalid values. | Med | High | We will have to manually test telemetry. Pinged people from telemetry for a code review | | An REST route returns invalid values. | Med | High | e2e tests caught some of these already. The rest of the code was re-checked by hand | | Deleted function/code might actually be still in use somewhere. | Low | High | e2e and unit tests should catch any of this. | ### Checklist Delete any items that are not applicable to this PR. - [x] [Unit or functional tests](https://www.elastic.co/guide/en/kibana/master/development-tests.html) were updated or added to match the most common scenarios |
||
---|---|---|
.. | ||
src | ||
BUILD.bazel | ||
jest.config.js | ||
package.json | ||
README.md | ||
tsconfig.json |
kbn-securitysolution-es-utils
This is the shared security solution elastic search utilities among plugins. This was originally created to remove the dependencies between security_solution and other projects such as lists. This should only be used within server side code and not client side code since it is all elastic search utilities and packages.