-
Notifications
You must be signed in to change notification settings - Fork 143
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
Stop providing mappings/settings for data indices #3013
Conversation
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 is the key piece of this PR. Removing this file in its entirety. All the rest of the diff is just adjusting to removing this code.
TIMESTAMP_FIELD = "_timestamp" | ||
DEFAULT_LANGUAGE = "en" |
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.
These constants were the only pieces from settings.py
that seemed worth keeping.
We could go farther and remove language
as a concept from connectors as well. However, this would require API changes and a change to the Protocol ("language"
field in the connector record), as well as a migration to remove it, so I'm opting to keep that vestigial for now.
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.
🚀 🌒
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.
@seanstory Sanity check - without default index mappings and settings, should we expect the framework to still work? If we create the connector via API, I’m pretty sure that index created by framework, with no "default" mappings will cause a failure.
At least that ^ was the case a while ago when I tried to attach a plain my-index
via API and that was manually created with PUT my-index
Not in scope: When creating the content index in Kibana, we also apply default mappings/settings—should we clean this up as well?
Should this be presented to breakign changes comittee? |
@joemcelroy is covering that as part of https://github.com/elastic/dev/issues/2880. This PR is just one of several that will go in to remove our usage of these mappings across the Search products.
I believe @joemcelroy is also on that. :) It's wider than just connector indices in Kibana, but all indices we create through that page, and he'll cover all use cases in one pass.
I've just double-checked and had no issue
As expected, the mappings are now Elastic defaults. Sync was successful. |
💔 Failed to create backport PR(s)The backport operation could not be completed due to the following error: The backport PRs will be merged automatically after passing CI. To backport manually run: |
Yup @seanstory, I recreated this and it worked! Nice 🚢 |
Closes #2962
Since their inception, Connectors have ensured that the data indices they write to use specific mappings/settings that were optimized for Elastic App Search. On their own (without App Search) these mappings/settings are likely to be pretty inefficient in terms of time and space, and don't follow Elastic conventions for default mappings/settings/subfield names.
The 9.0 major version bump is the right time to remove this opinionated approach to our output indices. Going forward, connectors should strive to be more agnostic. They will output JSON data. When customers want to customize their mappings, they will be able to do so from Elastic defaults, rather than the more arcane legacy App Search defaults.
This is a breaking change for anyone who expects an index created by connectors in 9.x to behave the same as one created in 8.x.
Checklists
Pre-Review Checklist
config.yml.example
)v7.13.2
,v7.14.0
,v8.0.0
)Release Note
Connectors will no longer be opinionated about output index mappings/settings. The Elastic default mappings/settings will be used after this change, rather than Connectors attempting to set their own convention of mappings/settings that were optimized for the legacy App Search product. If the old mappings/settings were desirable, they can still be set in advance by creating the index first, before pointing a connector to it.