-
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
Query string input - load index patterns instead of saved objects #84457
Conversation
Pinging @elastic/kibana-app-services (Team:AppServices) |
how is this related to #84458 ? |
@@ -174,6 +174,20 @@ export class IndexPatternsService { | |||
return this.savedObjectsCache; | |||
}; | |||
|
|||
find = async (search: string, size: number = 10): Promise<IndexPattern[]> => { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Should we add a unit test for this function?
const getIndexPatternPromises = savedObjects.map(async (savedObject) => { | ||
return await this.get(savedObject.id); | ||
}); | ||
return await Promise.all(getIndexPatternPromises); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
//nit isn't the await redundant?
@ppisljar Same problem in a different spot in the codebase. |
@elasticmachine merge upstream |
@elasticmachine merge upstream |
💚 Build SucceededMetrics [docs]Module Count
Async chunks
Distributable file count
Page load bundle
History
To update your PR or re-run it, just comment with: |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM
…astic#84457) * load index patterns instead of saved objects * remove getFromSavedObject * add test
Related to - #84352
Use index pattern service to load index pattern instance instead of loading saved object and transforming into index pattern like object. This correctly loads the field list.