-
Notifications
You must be signed in to change notification settings - Fork 8.3k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
[Data View Editor] Replace EmptyIndexPatternPrompt with NoDataViews component #126491
[Data View Editor] Replace EmptyIndexPatternPrompt with NoDataViews component #126491
Conversation
… from saved objects to exception lists (elastic#125182) ## Summary Exposes the functionality of * search_after * point in time (pit) From saved objects to the exception lists. This _DOES NOT_ expose these to the REST API just yet. Rather this exposes it at the API level to start with and changes code that had hard limits of 10k and other limited loops. I use the batching of 1k for this at a time as I thought that would be a decent batch guess and I see other parts of the code changed to it. It's easy to change the 1k if we find we need to throttle back more as we get feedback from others. See this PR where `PIT` and `search_after` were first introduced: elastic#89915 See these 2 issues where we should be using more paging and PIT (Point in Time) with search_after: elastic#93770 elastic#103944 The new methods added to the `exception_list_client.ts` client class are: * openPointInTime * closePointInTime * findExceptionListItemPointInTimeFinder * findExceptionListPointInTimeFinder * findExceptionListsItemPointInTimeFinder * findValueListExceptionListItemsPointInTimeFinder The areas of functionality that have been changed: * Exception list exports * Deletion of lists * Getting exception list items when generating signals Note that currently we use our own ways of looping over the saved objects which you can see in the codebase such as this older way below which does work but had a limitation of 10k against saved objects and did not do point in time (PIT) Older way example (deprecated): ```ts let page = 1; let ids: string[] = []; let foundExceptionListItems = await findExceptionListItem({ filter: undefined, listId, namespaceType, page, perPage: PER_PAGE, pit: undefined, savedObjectsClient, searchAfter: undefined, sortField: 'tie_breaker_id', sortOrder: 'desc', }); while (foundExceptionListItems != null && foundExceptionListItems.data.length > 0) { ids = [ ...ids, ...foundExceptionListItems.data.map((exceptionListItem) => exceptionListItem.id), ]; page += 1; foundExceptionListItems = await findExceptionListItem({ filter: undefined, listId, namespaceType, page, perPage: PER_PAGE, pit: undefined, savedObjectsClient, searchAfter: undefined, sortField: 'tie_breaker_id', sortOrder: 'desc', }); } return ids; ``` But now that is replaced with this newer way using PIT: ```ts // Stream the results from the Point In Time (PIT) finder into this array let ids: string[] = []; const executeFunctionOnStream = (response: FoundExceptionListItemSchema): void => { const responseIds = response.data.map((exceptionListItem) => exceptionListItem.id); ids = [...ids, ...responseIds]; }; await findExceptionListItemPointInTimeFinder({ executeFunctionOnStream, filter: undefined, listId, maxSize: undefined, // NOTE: This is unbounded when it is "undefined" namespaceType, perPage: 1_000, savedObjectsClient, sortField: 'tie_breaker_id', sortOrder: 'desc', }); return ids; ``` We also have areas of code that has perPage listed at 10k or a constant that represents 10k which this removes in most areas (but not all areas): ```ts const items = await client.findExceptionListsItem({ listId: listIds, namespaceType: namespaceTypes, page: 1, pit: undefined, perPage: MAX_EXCEPTION_LIST_SIZE, // <--- Really bad to send in 10k per page at a time searchAfter: undefined, filter: [], sortOrder: undefined, sortField: undefined, }); ``` That is now: ```ts // Stream the results from the Point In Time (PIT) finder into this array let items: ExceptionListItemSchema[] = []; const executeFunctionOnStream = (response: FoundExceptionListItemSchema): void => { items = [...items, ...response.data]; }; await client.findExceptionListsItemPointInTimeFinder({ executeFunctionOnStream, listId: listIds, namespaceType: namespaceTypes, perPage: 1_000, filter: [], maxSize: undefined, // NOTE: This is unbounded when it is "undefined" sortOrder: undefined, sortField: undefined, }); ``` Left over areas will be handled in separate PR's because they are in other people's code ownership areas. ### Checklist - [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
…d is visualized with visualizeGeoFieldAction (elastic#123540) * elastic#121908 - Maps usage tracking feature * #e-121908 - refactoring; Added naming constants for used apps; * elastic#121908 - updates for UiCounterMetricType, schema, metric analytics * elastic#121908 - refactoring; Fixed import syntax, type in report * elastic#121908 - refactoring * elastic#121908 - refactoring * 121908 - refactoring Co-authored-by: Kibana Machine <42973632+kibanamachine@users.noreply.github.com>
…etric unified renderer (elastic#125251) * Add `labelFont` and `LabelPosition` args in metric expression * Fix CI * Fixed remarks * Some fixes Co-authored-by: Kibana Machine <42973632+kibanamachine@users.noreply.github.com>
…tic#124124) * Add lens config options * wip * Pr feedback * simplify align * improve typing * update typing * PR feedback * Design PR feedback * snapshot * update snap * design suggestions * Use bottom as default position for title and some other small refactoring * Fix test * Fix shapshot * Fix shapshot Co-authored-by: Kibana Machine <42973632+kibanamachine@users.noreply.github.com> Co-authored-by: Uladzislau Lasitsa <Uladzislau_Lasitsa@epam.com>
* Shape argument turned to required. * Added checks for the gauge arguments. * Moved (metric/min/max/goal)Accessor arguments to (metric/min/max/goal). * Split gauge and lens state. * Added support of vis_dimensions. * Some fixes for uniformity. * Moved findAccessor out of dimensions. * Made accessors/vis_dimension functionality reusable for other plugins. * Fixed test snapshots. * Fixed snapshots. Co-authored-by: Kibana Machine <42973632+kibanamachine@users.noreply.github.com>
* use discover locator in obs plugin * move import up
…_range, number_range and date_range (elastic#125389) * allow last value, min and max on dates * fix tests * fix typo * fix tests * nit Co-authored-by: Kibana Machine <42973632+kibanamachine@users.noreply.github.com>
Replaces previous `config.get` pattern typed to `string | undefined` with a full `MonitoringConfig` type.
* added loading spinner to add agent flyout * fixed create agent policy scenario
elastic#125772) **Addresses:** elastic#125502 ## Summary Removed the `rulesBulkEditEnabled` experimental flag from the config and its usage from the client-side code.
[Workplace Search] Add indexing rules table
…bug (elastic#124909) ### Summary Addresses elastic#124742 #### Issue TLDR Import of rules that reference exception items with comments fail. Failure message states that comments cannot include `created_at`, `created_by`, `id`.
Co-authored-by: Tyler Smalley <tyler.smalley@elastic.co> Co-authored-by: Kibana Machine <42973632+kibanamachine@users.noreply.github.com>
…ted_field.json (elastic#125321) * remove es_archive with kbn_archive invalid_scripted_field.json * remove unused es_archive files * replace another usage of es_archives/invalid_scripted_field * clear any existing index patterns before loading our new one * remove .only Co-authored-by: Kibana Machine <42973632+kibanamachine@users.noreply.github.com>
This reverts commit 680ef03.
…est (elastic#125784) Co-authored-by: Kibana Machine <42973632+kibanamachine@users.noreply.github.com>
* [Snapshot & Restore] Fix repository types on Cloud * [Snapshot & Restore] Move repo types tests into `on-prem` describe block Co-authored-by: Kibana Machine <42973632+kibanamachine@users.noreply.github.com>
Co-authored-by: Andrea Del Rio <delrio.andre@gmail.com>
…5673) * Move stripping unsafe headers to the screenshotting plugin * Encapsulate conditional headers handling in the screenshotting plugin * Add KibanaRequest support on input
040b11e
to
e5a527b
Compare
e5a527b
to
da2dee8
Compare
💔 Build FailedFailed CI StepsMetrics [docs]Module Count
Public APIs missing comments
Async chunks
Page load bundle
Unknown metric groupsAPI count
async chunk count
ESLint disabled in files
Total ESLint disabled count
History
To update your PR or re-run it, just comment with: |
closing in favor of: #127941 |
Summary
This PR replaces the
EmptyIndexPatternPrompt
component with theNoDataViews
component from theshared-ux
plugin. Since all plugins should use theshared-ux
component now, no need to maintain the two componentsThe problem with
DataViewEditor
consumingSharedUX
bundle directly is that it would create a circular dependency, sinceSharedUX
had a dependency onDataViewEditor
. In order to overcome that, I've created a separateshared_ux_components
plugin that would contain only pure components and have no external dependencies. But I don't really like this approach, so open to suggestions.Checklist
Delete any items that are not applicable to this PR.
Risk Matrix
Delete this section if it is not applicable to this PR.
Before closing this PR, invite QA, stakeholders, and other developers to identify risks that should be tested prior to the change/feature release.
When forming the risk matrix, consider some of the following examples and how they may potentially impact the change:
For maintainers