mirror of
https://github.com/elastic/kibana.git
synced 2025-04-24 17:59:23 -04:00
## Summary Partially addresses https://github.com/elastic/kibana/issues/152224 [Tech Doc (private)](https://docs.google.com/document/d/1ssYmqSEUPrsuCR4iz8DohkEWekoYrm2yL4QR_fVxXLg/edit#heading=h.6sj4n6bjcgp5) Introduce `mSearch` - temporary cross-content type search layer for content management backed by `savedObjects.find` Until we have [a dedicated search layer in CM services](https://docs.google.com/document/d/1mTa1xJIr8ttRnhkHcbdyLSpNJDL1FPJ3OyK4xnOsmnQ/edit), we want to provide a temporary solution to replace client-side or naive server proxy usages of `savedObjects.find()` across multiple types with Content Management API to prepare these places for backward compatibility compliance. Later we plan to use the new API together with shared components that work across multiple types like `SavedObjectFinder` or `TableListView` The api would only work with content types that use saved objects as a backend. To opt-in a saved object backed content type to `mSearch` need to provide `MSearchConfig` on `ContentStorage`: ``` export class MapsStorage implements ContentStorage<Map> { // ... mSearch: { savedObjectType: 'maps', toItemResult: (ctx: StorageContext, mapsSavedObject: SavedObject<MapsAttributes>) => toMap(ctx,mapsSavedObject), // transform, validate, version additionalSearchFields: ['something-maps-specific'], } } ``` *Out of scope of this PR:* - tags search (will follow up shortly) - pagination (as described in [the doc]([Tech Doc](https://docs.google.com/document/d/1ssYmqSEUPrsuCR4iz8DohkEWekoYrm2yL4QR_fVxXLg/edit#heading=h.6sj4n6bjcgp5)) server-side pagination is not needed for the first consumers, but will follow up shortly) - end-to-end / integration testing (don't want to introduce a dummy saved object for testing this, instead plan to wait for maps CM onboard and test using maps https://github.com/elastic/kibana/pull/153304) - Documentation (will add into https://github.com/elastic/kibana/pull/154453) - Add rxjs and hook method |
||
---|---|---|
.. | ||
bfetch_explorer | ||
content_management_examples | ||
controls_example | ||
data_view_field_editor_example | ||
developer_examples | ||
embeddable_examples | ||
embeddable_explorer | ||
expressions_explorer | ||
field_formats_example | ||
files_example | ||
guided_onboarding_example | ||
hello_world | ||
locator_examples | ||
locator_explorer | ||
partial_results_example | ||
portable_dashboards_example | ||
preboot_example | ||
response_stream | ||
routing_example | ||
screenshot_mode_example | ||
search_examples | ||
share_examples | ||
state_containers_examples | ||
ui_action_examples | ||
ui_actions_explorer | ||
user_profile_examples | ||
README.asciidoc |
[[example-plugins]] == Example plugins This folder contains example plugins. To run the plugins in this folder, use the `--run-examples` flag, via [source,bash] ---- yarn start --run-examples ----