-
Notifications
You must be signed in to change notification settings - Fork 25.6k
ESQL: Fix some more usages of field attribute names in LOOKUP JOIN #129355
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
Changes from 6 commits
08be01c
44dca94
35ed8ea
646f378
e3ef5c2
8dfd4dc
4858b1d
4db8c81
a3da244
82d359b
0a87d8b
6634289
3470281
213f5df
77c5835
7f98271
db3b5bb
e86539b
9d4102e
bf01b0d
f0f4b48
3a8594e
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 |
|---|---|---|
|
|
@@ -766,10 +766,10 @@ private PhysicalOperation planLookupJoin(LookupJoinExec join, LocalExecutionPlan | |
| ); | ||
| } | ||
|
|
||
| private record MatchConfig(String fieldName, int channel, DataType type) { | ||
| private record MatchConfig(FieldAttribute.FieldName fieldName, int channel, DataType type) { | ||
| private MatchConfig(FieldAttribute match, Layout.ChannelAndType input) { | ||
| // Note, this handles TEXT fields with KEYWORD subfields | ||
| this(match.exactAttribute().name(), input.channel(), input.type()); | ||
| this(match.exactAttribute().fieldName(), input.channel(), input.type()); | ||
|
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. It is not quite obvious to me how the keyword subfield of a text field works with multi-typed field, it will be great if we have a test to exercise this code path, or some comments for when 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. Honestly, I think this line is super redundant. The matchfield is a field from the lookup index. We can't even use TEXT as a lookup key in the lookup index, it's only allowed in the main index. So the dropping down to the exact subfield just doesn't ever apply. I'll expand the comment. Testing this code path is currently not really possible (at least not in a realistic scenario.) In any case, using |
||
| } | ||
| } | ||
|
|
||
|
|
||
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.
Thanks for adding tests for multi-typed numeric fields as join keys. We still have gaps in test coverage for multi-typed join keys involving string types (keyword, text, ip) and date types (millis, nanos). If these are not within the scope of this PR, they should be covered in a separate one.
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.
Added a more complete list of tests to
LookupJoinTypesIT. It's still not exhaustive but IMO covers enough ground for now.That required a bit of refactoring ^^