-
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
Introduce aliases for data streams #66163
Comments
Pinging @elastic/es-core-features (Team:Core/Features) |
…action.Alias class. This change is part of series of changes to clean up the usage `IndexAbstraction.Alias` in the codebase, so that it is no longer needed to cast to `IndexAbstraction.Alias` and just use the methods on the `IndexAbstraction` interface. This should help adding data stream aliases, so that `IndexAbstraction` instances of type `ALIAS` can also be data stream aliases. Relates to elastic#66163
Big +1 on this one. That will simplify lots of things.
Not allowing aliases to refer to regular indices and data streams at the same time seems like a big limitation. I suppose that limitation could be relaxed later? I suppose authorization would be tricky to determine for aliases pointing to data streams and regular indices. |
We could think about relaxing it later, because essentially even a data stream will resolve to indices. However like you mention there can be complications, especially if we endup having different authorization schemes for aliases pointing to indices and aliases pointing to data streams. |
…related casts. This change is part of series of changes to clean up the usage IndexAbstraction.Alias in the codebase, so that it is no longer needed to cast to IndexAbstraction.Alias and just use the methods on the IndexAbstraction interface. This should help adding data stream aliases, so that IndexAbstraction instances of type ALIAS can also be data stream aliases. Relates to elastic#66163
and change validation to be an implementation detail and part of construction of the alias abstraction. This change is part of series of changes to clean up the usage IndexAbstraction.Alias in the codebase, so that it is no longer needed to cast to IndexAbstraction.Alias and just use the methods on the IndexAbstraction interface. This should help adding data stream aliases, so that IndexAbstraction instances of type ALIAS can also be data stream aliases. Relates to elastic#66163
and change validation to be an implementation detail and part of construction of the alias abstraction. This change is part of series of changes to clean up the usage IndexAbstraction.Alias in the codebase, so that it is no longer needed to cast to IndexAbstraction.Alias and just use the methods on the IndexAbstraction interface. This should help adding data stream aliases, so that IndexAbstraction instances of type ALIAS can also be data stream aliases. Relates to #66163
and change validation to be an implementation detail and part of construction of the alias abstraction. This change is part of series of changes to clean up the usage IndexAbstraction.Alias in the codebase, so that it is no longer needed to cast to IndexAbstraction.Alias and just use the methods on the IndexAbstraction interface. This should help adding data stream aliases, so that IndexAbstraction instances of type ALIAS can also be data stream aliases. Relates to elastic#66163
and change validation to be an implementation detail and part of construction of the alias abstraction. Backport of #66508 to 7.x branch. This change is part of series of changes to clean up the usage IndexAbstraction.Alias in the codebase, so that it is no longer needed to cast to IndexAbstraction.Alias and just use the methods on the IndexAbstraction interface. This should help adding data stream aliases, so that IndexAbstraction instances of type ALIAS can also be data stream aliases. Relates to #66163
…action.Alias class (#66165) This change is part of series of changes to clean up the usage `IndexAbstraction.Alias` in the codebase, so that it is no longer needed to cast to `IndexAbstraction.Alias` and just use the methods on the `IndexAbstraction` interface. This should help adding data stream aliases, so that `IndexAbstraction` instances of type `ALIAS` can also be data stream aliases. Relates to #66163
…action.Alias class Backporting elastic#66165 to 7.x branch. This change is part of series of changes to clean up the usage `IndexAbstraction.Alias` in the codebase, so that it is no longer needed to cast to `IndexAbstraction.Alias` and just use the methods on the `IndexAbstraction` interface. This should help adding data stream aliases, so that `IndexAbstraction` instances of type `ALIAS` can also be data stream aliases. Relates to elastic#66163
…action.Alias class (#67161) Backporting #66165 to 7.x branch. This change is part of series of changes to clean up the usage `IndexAbstraction.Alias` in the codebase, so that it is no longer needed to cast to `IndexAbstraction.Alias` and just use the methods on the `IndexAbstraction` interface. This should help adding data stream aliases, so that `IndexAbstraction` instances of type `ALIAS` can also be data stream aliases. Relates to #66163
…related casts. (#66178) This change is part of series of changes to clean up the usage IndexAbstraction.Alias in the codebase, so that it is no longer needed to cast to IndexAbstraction.Alias and just use the methods on the IndexAbstraction interface. This should help adding data stream aliases, so that IndexAbstraction instances of type ALIAS can also be data stream aliases. Relates to #66163
…related casts. Backport elastic#66178 to 7.x branch. This change is part of series of changes to clean up the usage IndexAbstraction.Alias in the codebase, so that it is no longer needed to cast to IndexAbstraction.Alias and just use the methods on the IndexAbstraction interface. This should help adding data stream aliases, so that IndexAbstraction instances of type ALIAS can also be data stream aliases. Relates to elastic#66163
…related casts. (#67176) Backport #66178 to 7.x branch. This change is part of series of changes to clean up the usage IndexAbstraction.Alias in the codebase, so that it is no longer needed to cast to IndexAbstraction.Alias and just use the methods on the IndexAbstraction interface. This should help adding data stream aliases, so that IndexAbstraction instances of type ALIAS can also be data stream aliases. Relates to #66163
This allows specifying a query as filter on data stream alias, which will then always be applied when searching via this alias. Relates elastic#66163
@martijnvg Thanks for introducing aliases to data stream, it's a much needed feature!
Recently, I upgraded our ELK setup to
|
Thanks @Alsheh, I totally agree. The whole point of aliases is imho so we can migrate to datastreams and that the existing dashboards and visualisations keep working.. |
Thanks @Alsheh for trying out data stream aliases!
I see, I think we can relax this limitation and allow a data stream alias and an index alias to share the same name. The limitation comes from being overprotective about the fact that data stream aliases and index aliases are stored in different places in the cluster state. I will look into this and see whether this limitation can really be lifted.
An error should be returned. Not sure why this didn't happen, but this looks like a bug. |
Alias for datastream is supported since elastic#66163. Currently alias for the backing indices are still not allowed. As a result, the error messages are updated to reflect the latest status.
Alias for datastream is supported since #66163. Currently alias for the backing indices are still not allowed. As a result, the error messages are updated to reflect the latest status.
Alias for datastream is supported since elastic#66163. Currently alias for the backing indices are still not allowed. As a result, the error messages are updated to reflect the latest status.
Has this been implemented? |
+1 really need this, what about on indices made by rollovers in ILM..for instance all filebeat-* , auditbeat-* ? |
+1 Not allowing aliases is preventing us from migrating to Data Streams. We have quite a lot of things referencing multiple indices by aliases, so the lack of aliases on data streams would break our entire deployment. For instance, the alias |
@martijnvg martijn |
Pinging @elastic/es-data-management (Team:Data Management) |
Any new about this urgent issue? Talking about "Support aliases that point to both regular indices and data streams" |
... |
Bump for current engagement re-asking about this Enhancement. They need various periods of dual-ingestion (migrating reg indices to data streams) and always the ability to query across both. |
When a datastream has a template and that template defines which aliases the datastream should have. That work fine. However, when I later alter the template to have new aliases/remove old aliases, upload the altered template and do a _rollover on the datastream. The new indices have the aliases defined in the altered template, but not those indices created before the template was altered. When I realised this, I tried to alter each index in the datastream by adding and removing aliases the way you can on legacy indices, but then I get an error saying that the indices are a part of a datastream and I am not allowed to change the aliases. This is a little bit frustrating in an environment where we use aliases a lot to create "views" for the end users. It is also a problem when and if there is a change request asking to change the alias name. I have not been able to find a way to change an alias other than adding the alias to the template, upload it, rollover the stream and then telling the end user that only new data will be found under the new alias and the old data will be accessible from the old alias until the content is deleted by the lifecycle management. |
Currently aliases can only refer to indices. This issue is about extending that ability to data streams.
In order to reduce complexity aliases for data streams will behave differently than aliases for indices. Data stream aliases should only be able to refer to data streams. A data stream alias should not be able to refer to a backing index or any other regular index.
Aliases pointing to data streams will implementation wise be different than aliases pointing to indices. Data stream aliases will refer to data stream names. This should automatically allow resolvability to all backing indices of a data stream, even when rollovers have occurred. Data stream aliases are separately stored next to data streams in the cluster state.
Authorization shouldn't be defined on the alias level, but be determined by the authorization defined on the data stream level.Ideally we should reuse the current aliases api in order to allow users to define aliases for data streams.
Data stream aliases should at least support the following functionality:
logs
alias that point tologs-http
andlogs-my-application
data stream.I currently do not see use cases where we need to be able to support index and search routing on aliases for data streams.
Being able to define a filter on a data stream alias seems to make sense to me, but I think when needed can be added as a follow up.
Tasks:
The text was updated successfully, but these errors were encountered: