Hide Elasticsearch prefix-based pass-through query behind feature toggle#14015
Conversation
b72026e to
650405b
Compare
There was a problem hiding this comment.
Use PLANNER_CONTEXT.getTypeManager()
then you can revert TestingTypeManager changes
650405b to
fc104b1
Compare
26c958a to
f526f6a
Compare
There was a problem hiding this comment.
I am not sure if it comes from you or is it is a bad rebase.
There was a problem hiding this comment.
please invert the condition then you can return fast and avoid indentation. You will avoid changing lines. Easier to review ;)
if (!constraint) {
throw exception
}
the old code
There was a problem hiding this comment.
We don't do such testing ;) We try to avoid plumbing. Instead please create a new test class that extends abstract test query framewok and create new query runner that query pass through disabled. Then you can simply do assertQueryFail
There was a problem hiding this comment.
it is default value for boolean field
54fd7c5 to
8e92c83
Compare
8e92c83 to
facb98a
Compare
We have two "pass-through queries"
please make sure the commit title indicates which one is getting behind a toggle and also add rationale to the commit message |
kokosing
left a comment
There was a problem hiding this comment.
looks good to me % comments and CI
Thanks! It looks much simpler now!
There was a problem hiding this comment.
TestDisabledLegacyPassThroughQuery
There was a problem hiding this comment.
Please recommend that PTF (table function based) query pass through should be used instead.
There was a problem hiding this comment.
@findepi I would use elasticsearch.legacy-pass-through-query.enabled. WDYT?
|
ES build is failing |
f99da85 to
65f9093
Compare
de81690 to
1651d4b
Compare
kokosing
left a comment
There was a problem hiding this comment.
% comment. Please rebase and squash commits.
There was a problem hiding this comment.
You are using elasticsearch.legacy-pass-through-query.enabled in code. Please update.
98cf35b to
0c0bfbe
Compare
Prefix based pass-through query is deprecated, raw_query table function should be used instead.
0c0bfbe to
4016a90
Compare
...icsearch/src/test/java/io/trino/plugin/elasticsearch/TestDisabledLegacyPassThroughQuery.java
Outdated
Show resolved
Hide resolved
|
Thank you! |
|
Thank you for including the docs for this change as well! |
Description
Hides Elasticsearch prefix-based pass-through query behind a feature toggle as discussed here #13390
The prefix-based pass-through query is deprecated. the
raw_querytable function should be used instead. To emphasize the fact that prefix-based pass-through query is deprecated before removing it at all, we decided to hide it behind the feature toggle.Release notes
( ) This is not user-visible and no release notes are required.
(x) Release notes are required, please propose a release note for me.
( ) Release notes are required, with the following suggested text: