-
Notifications
You must be signed in to change notification settings - Fork 25k
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
Add semantic_text to mapping_all_types and switch to TranslationAware in PushFiltersToSource #118982
Add semantic_text to mapping_all_types and switch to TranslationAware in PushFiltersToSource #118982
Changes from all commits
683a843
b3c6f7c
9dc94fc
ced0519
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
Original file line number | Diff line number | Diff line change | ||||||||||||||||||||||||||||
---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
|
@@ -31,7 +31,6 @@ | |||||||||||||||||||||||||||||
import org.elasticsearch.xpack.esql.core.util.CollectionUtils; | ||||||||||||||||||||||||||||||
import org.elasticsearch.xpack.esql.core.util.Queries; | ||||||||||||||||||||||||||||||
import org.elasticsearch.xpack.esql.expression.function.fulltext.FullTextFunction; | ||||||||||||||||||||||||||||||
import org.elasticsearch.xpack.esql.expression.function.fulltext.Term; | ||||||||||||||||||||||||||||||
import org.elasticsearch.xpack.esql.expression.function.scalar.ip.CIDRMatch; | ||||||||||||||||||||||||||||||
import org.elasticsearch.xpack.esql.expression.function.scalar.spatial.BinarySpatialFunction; | ||||||||||||||||||||||||||||||
import org.elasticsearch.xpack.esql.expression.function.scalar.spatial.SpatialRelatesFunction; | ||||||||||||||||||||||||||||||
|
@@ -252,8 +251,6 @@ static boolean canPushToSource(Expression exp, LucenePushdownPredicates lucenePu | |||||||||||||||||||||||||||||
&& Expressions.foldable(cidrMatch.matches()); | ||||||||||||||||||||||||||||||
} else if (exp instanceof SpatialRelatesFunction spatial) { | ||||||||||||||||||||||||||||||
return canPushSpatialFunctionToSource(spatial, lucenePushdownPredicates); | ||||||||||||||||||||||||||||||
} else if (exp instanceof Term term) { | ||||||||||||||||||||||||||||||
return term.field() instanceof FieldAttribute && DataType.isString(term.field().dataType()); | ||||||||||||||||||||||||||||||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. This was redundant indeed, I tried it quickly and it works fine (the verifier prevents these cases). nit: If you have a chance, it would be good to have a VerifierTest that checks that things like There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. I think this is already tested: Lines 86 to 99 in 9424bd2
|
||||||||||||||||||||||||||||||
} else if (exp instanceof FullTextFunction) { | ||||||||||||||||||||||||||||||
return true; | ||||||||||||||||||||||||||||||
} | ||||||||||||||||||||||||||||||
|
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.
❤️