Skip to content
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

Migrate saved-object types between indices #90817

Closed
kobelb opened this issue Feb 9, 2021 · 3 comments
Closed

Migrate saved-object types between indices #90817

kobelb opened this issue Feb 9, 2021 · 3 comments
Labels
Feature:Saved Objects Team:Core Core services & architecture: plugins, logging, config, saved objects, http, ES client, i18n, etc

Comments

@kobelb
Copy link
Contributor

kobelb commented Feb 9, 2021

Saved-object types can choose their index by specifying the indexPattern field. However, it's not currently possible to move an existing saved-object type between indices. This forces us to have the adequate foresight to put the saved-objects in their proper long-term indices, which isn't feasible as predicting the future is impossible (don't tell hedge fund managers).

#70471 proposes an alternative option where each saved-object type would be in its own index. If we pursue this approach, this issue is irrelevant.

@kobelb kobelb added Team:Core Core services & architecture: plugins, logging, config, saved objects, http, ES client, i18n, etc Feature:Saved Objects labels Feb 9, 2021
@elasticmachine
Copy link
Contributor

Pinging @elastic/kibana-core (Team:Core)

@pgayvallet
Copy link
Contributor

pgayvallet commented Feb 12, 2021

#70471 proposes an alternative option where each saved-object type would be in its own index

I think there is a significant distinction between having a distinct index for each SO types, and adding the capability to let types move around from one index to another.

If we decide to switch to one index per type, this could be done at a specific version in a deterministic manner (even if the SO migration isn't supporting that right now)

Allowing the types to switch from an index to another during an arbitrary migration seems harder. Biggest concern here imho would be how to find the list of previous indices the type document may be in. E.g, the foo type changes from index foo to bar-was-better in 7.14, and then from bar-was-better to dolly-is-the-way in 7.15. We would need to keep an explicit track of the index-per-version map.

@pgayvallet
Copy link
Contributor

Even if this was a one-shot, we do have the option to perform it again when required, so I would consider this issue as solved by #154888 in the scope of #104081

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Feature:Saved Objects Team:Core Core services & architecture: plugins, logging, config, saved objects, http, ES client, i18n, etc
Projects
None yet
Development

No branches or pull requests

3 participants