Cutover aggs to the new platform#59605
Conversation
|
Pinging @elastic/kibana-app-arch (Team:AppArch) |
59d7a0d to
79495f9
Compare
ba448d7 to
c2e811e
Compare
5b69e10 to
c776aba
Compare
There was a problem hiding this comment.
This is a one-line function so I inlined it here rather than importing from legacy kibana plugin as we had done previously.
There was a problem hiding this comment.
Kept these empty interfaces in place because there were a few areas in Kibana still using them. (trying to keep things as small as possible).
There was a problem hiding this comment.
@lizozom said this will be going away shortly
src/plugins/data/common/index.ts
Outdated
There was a problem hiding this comment.
Removed this export because now the only thing in utils is internal to other items in the common directory.
src/plugins/data/kibana.json
Outdated
There was a problem hiding this comment.
expressions is now required to register esaggs function
src/plugins/data/public/plugin.ts
Outdated
There was a problem hiding this comment.
createFiltersFromEvent is technically stateful as it relies on index patterns behind the scenes. Open to suggestions on where this should live, but in its current form it cannot be exported statically @ppisljar
There was a problem hiding this comment.
Now that this has been wrapped with a provider pattern, we can (as a follow up step) get rid of the getters/setters that are currently being used to retrieve stateful services in each agg type, and instead explicitly pass those deps down.
There was a problem hiding this comment.
might make sense to pass down something that can be same on client and server (like getConfig function)
There was a problem hiding this comment.
This still lives as a test helper inside search.aggs, but might be more generically useful elsewhere in the data plugin. Perhaps we consider eventually moving it up to a different directory
There was a problem hiding this comment.
Changed this to casting because there was a circular dependency going back to require the search.aggs mocks, and it felt unnecessary to duplicate the entire search service contract here
There was a problem hiding this comment.
calculateObjectHash wasn't exported at the top level so I added it here, and alphabetized
This comment has been minimized.
This comment has been minimized.
This comment has been minimized.
This comment has been minimized.
c776aba to
399c193
Compare
cc19af4 to
3094c26
Compare
3094c26 to
36d078d
Compare
aa00d90 to
fcfa468
Compare
💚 Build SucceededHistory
To update your PR or re-run it, just comment with: |
joshdover
left a comment
There was a problem hiding this comment.
Migration guide changes LGTM. Thanks for making the plugins. prefix more clear 😄
sulemanof
left a comment
There was a problem hiding this comment.
LGTM, mostly checked the default editor changes, great work!
|
I will review this PR today. |
flash1293
left a comment
There was a problem hiding this comment.
Tested and couldn't find any problems, LGTM 👍
Summary
Moves
agg_typesinto the new platform under thedataplugin'ssearchservice. Once this PR is merged, it should unblock anybody waiting on the rest of the search service to move to the new platform.Some specific items moved include:
agg_typesesaggstabifyAt this point there is nothing left in
src/legacy/core_plugins/datathat anybody should need to rely on... anything there is getting left behind for BWC and can be completely deleted when downstream apps complete migration.For reviewers
If you got pinged for a codeowners review, don't be intimidated by the size of this PR 😬
Most of the significant changes here affect code owned by app arch, but since nearly all of the code has been removed from
src/legacy/core_plugins/dataat this point, imports needed to be updated across the project. In most cases you should only have a few changed lines of code to review.For those reviewing large portions of the PR, I recommend going commit-by-commit instead of attempting to peruse the whole thing. I've tried to keep a coherent commit history so it should make things somewhat easier to follow.
For QA
This PR should introduce no functional changes to Kibana; it is 100% internal refactoring as we migrate our search aggregation infrastructure to the new platform.
Additional info
dataplugin, a ton of markdown files were createdui/agg_typeswere preserved for BWC and to minimize the changes that need to go into this (already large) PR.core_plugins/datahas been preserveddata/common. This includesparseEsInterval,dateHistogramInverval,isValidEsInterval, etc.ui/new_platformto ensure functionality that was necessary for the legacy platform still works without the legacy data pluginDev docs
I am skipping docs on this PR, as the documentation is being added to the 7.7 ui/public cleanup documentation issue.