-
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
Counted keyword synthetic source: inherit source keep mode from index settings #120678
Counted keyword synthetic source: inherit source keep mode from index settings #120678
Conversation
This reverts commit 025063f.
Pinging @elastic/es-storage-engine (Team:StorageEngine) |
assertThat(actual, equalTo(expected)); | ||
} | ||
|
||
public void testSyntheticSourceInheritsKeepAll() throws IOException { |
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.
This functionality doesn't exist right?
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.
Right, it's actually just testing that the object mapper is capturing the source. If you want, I can remove the test.
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.
Such test should exist elsewhere i would remove it.
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.
Will do!
|
||
--- | ||
|
||
"synthetic_source_keep value is respected": |
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.
Do we test nested arrays anywhere?
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.
It's tested in MapperTestCase::testSyntheticSourceKeepArrays
, but I'll add a few cases to the yamlRestTest too.
…erit-index-keep-source
…erit-index-keep-source
Backport PR for 8.x opened, #120871 |
… (#120871) This patch adds a property to CountedKeywordMapper to track the synthetic_source_keep index setting. This property is then used to properly implement synthetic source support in the counted_keyword field type, with fallback to the ignore_source mechanism when synthetic_source_keep is set in either the field mapping or the index settings.
This PR adds a mechanism to track the value of the
synthetic_source_keep
setting if it is set in the index settings. This value is then used to properly implement synthetic source support in thecounted_keyword
field type.This PR also adds tests to verify that if
synthetic_source_keep
is set in the index settings, it is respected by theCountedKeywordFieldMapper
.Unlike #120426, this implementation does not inherit
synthetic_source_keep
from ancestor object nodes.Follow-up to #120078
Relates to #109796