-
Notifications
You must be signed in to change notification settings - Fork 8.1k
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 - Query Service] Move es-query back into a dedicated package #51659
Labels
blocker
chore
Feature:KQL
KQL
impact:critical
This issue should be addressed immediately due to a critical level of impact on the product.
loe:large
Large Level of Effort
NeededFor:Core
v8.0.0
Comments
lukeelmers
added
chore
Team:Core
Core services & architecture: plugins, logging, config, saved objects, http, ES client, i18n, etc
Feature:KQL
KQL
Team:AppArch
Feature:NP Migration
labels
Nov 25, 2019
This was referenced Nov 25, 2019
lukeelmers
added
blocker
and removed
Team:Core
Core services & architecture: plugins, logging, config, saved objects, http, ES client, i18n, etc
labels
May 13, 2020
lukeelmers
changed the title
[Data - Query Service] Create server API to use KQL in Saved Object queries
[Data - Query Service] Move es-query back into a dedicated package
Mar 11, 2021
exalate-issue-sync
bot
added
impact:critical
This issue should be addressed immediately due to a critical level of impact on the product.
loe:small
Small Level of Effort
loe:medium
Medium Level of Effort
and removed
loe:small
Small Level of Effort
labels
Apr 26, 2021
Dependencies
|
9 tasks
This was referenced Jun 23, 2021
exalate-issue-sync
bot
added
loe:large
Large Level of Effort
and removed
loe:medium
Medium Level of Effort
labels
Jul 12, 2021
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Labels
blocker
chore
Feature:KQL
KQL
impact:critical
This issue should be addressed immediately due to a critical level of impact on the product.
loe:large
Large Level of Effort
NeededFor:Core
v8.0.0
In #42012 it was decided that we would move the
@kbn/es-query
package into thedata
plugin, which was merged in #51014.In #41136, functionality was added to Saved Objects Client which allowed filtering using a KQL string. Internally, core was using the former
@kbn/es-query
package to parse the KQL.Since es-query is no longer a standalone package, this means a dependency has been created between core (which owns saved objects), and data (which owns KQL). Having core depend on any other plugins runs counter to the overall design of the Kibana platform and blocks the upcoming migration to Bazel, so we need to go back and remove this dependency.
For the reasons discussed in #55485, core & app services agreed we should revert back to the previous approach of having es-query live as a standalone package of some type.
Edit The revised plan:
fromKueryExpression
,toElasticsearchQuery
, andnodeTypes.function.buildNode
, so at a minimum those functions are what need to be movedes-query
relies on from data (they will need to be moved into a package as well, otherwise they must be duplicated).IIndexPattern
is the biggest potential issue here, but if we also movedQuery
,Filter
,TimeRange
, it would help with circular dependency issues we've hit elsewhere.es-query
package, or perhaps a separatedata-types
package as suggested in [core.savedObjects] Update esKuery imports to pull from new package instead of data plugin #55485 (comment)src/plugins/expressions/server/index.ts
fromtsconfig.types.json
scripts/check_unpublished_api_changes
compile errors which occurred as a result of core's dependency on data.The plan discussed with @rudolf, @joshdover, and @Bargs is as follows:- [ ] 1. @elastic/kibana-platform - #55485 Expose a generic ES filter api for Saved Objects find- [ ] 2. @elastic/kibana-app-arch - After (1) is complete:- [ ] Create a server API in the Data Query Service that can take Saved Object Client & a KQL query and validate/compile the KQL to an ES Filter which is passed to the SO client- We should be able to reuse a lot of the existing code that does this from/src/core/server/saved_objects/service/lib/filter_utils.ts
for this.- [ ] Removesrc/plugins/expressions/server/index.ts
fromtsconfig.types.json
- This was added in #64395 to preventscripts/check_unpublished_api_changes
compile errors which occurred as a result of core's dependency on data.The text was updated successfully, but these errors were encountered: