kibana/docs/developer
Søren Louv-Jansen 7df1cee163
[APM] Add data access plugin (#162367)
Closes https://github.com/elastic/kibana/issues/161906
Related to:
https://github.com/elastic/observability-dev/discussions/2787
(_internal_)

This add a new plugin `apm_data_access` that contains the APM query
targets (indices to query for APM data).
This plugin can be consumed by apm and any other plugin, making it
possible for other plugins to know about the configured APM query
targets.



## Example:

APM query targets can be specified in kibana[.dev].yml using
`xpack.apm.indices.{dataset}: some-index-*` for instances:

```yml
xpack.apm.indices.transaction: apm-*
```

See all config options on:
https://www.elastic.co/guide/en/kibana/current/apm-settings-kb.html#general-apm-settings-kb

Query targets can also be specified via the UI (and persisted in a saved
object) via the settings page: `/app/apm/settings/apm-indices`

**Retrieving the query targets**
Query targets can be retrieved from other plugins via `getApmIndices`:
```ts
const apmIndices = await plugins.apmDataAccess.setup.getApmIndices(savedObjects.client); 
```

TODO:

- [x] Add SO client and fetch space aware index config (see
4d7f626da0/x-pack/plugins/apm/server/routes/settings/apm_indices/get_apm_indices.ts (L32-L44))
- [ ] Add simple APM client for querying apm data

---------

Co-authored-by: kibanamachine <42973632+kibanamachine@users.noreply.github.com>
2023-08-22 02:19:09 -07:00
..
advanced Upgrade Node.js to 18.17.1 (#163710) 2023-08-14 12:08:27 -05:00
architecture Update core architecture docs (#164120) 2023-08-21 15:38:24 -04:00
best-practices [Documentation] Fix links to repository files on Best Practices page (#96152) 2022-12-21 14:16:11 -07:00
contributing [DOCS] Remove or move book-scoped attributes (#155210) 2023-04-20 09:12:09 -07:00
getting-started Updating debugging docs: replacing apm.dev.js configuration references with kibana.dev.yml (#152237) 2023-03-08 14:43:34 +00:00
images docs: interpreting ci failures (#153549) 2023-03-24 17:27:11 +01:00
plugin [docs] remove invalid arg from scripts/generate_plugin example (#159466) 2023-06-14 12:07:18 +02:00
index.asciidoc Add more details on developer documentation (#126674) 2022-03-03 11:44:05 -07:00
plugin-list.asciidoc [APM] Add data access plugin (#162367) 2023-08-22 02:19:09 -07:00
telemetry.asciidoc [dev/cli/timings] report on time to dev server listening (#95120) 2021-03-24 18:45:24 -04:00