Skip to content

Loading…

Allow setting aliases on index template #1825

Closed
tsouza opened this Issue · 6 comments

6 participants

@tsouza

Allow setting aliases on index template so the newly created index is automatically assigned to the alias.

@TwP

This would be a useful feature. :+1:

@javanna javanna was assigned
@rbraley

this would be great

@javanna javanna added a commit to javanna/elasticsearch that referenced this issue
@javanna javanna finalized support for aliases in index templates
- adapted existing PR to updated code
- resolved TODOs
- added more tests (including REST test)

Closes #1825
21c8131
@javanna javanna added a commit to javanna/elasticsearch that referenced this issue
@javanna javanna finalized support for aliases in index templates
- adapted existing PR to updated code
- resolved TODOs
- added more tests (including REST test)

Closes #1825
7b7a23d
@javanna javanna added a commit to javanna/elasticsearch that referenced this issue
@javanna javanna Finalized support for aliases in index templates
- adapted existing PR to updated code (post #4920)
- resolved TODOs (bw compatible serialization etc.)
- added more tests

Closes #1825
095333e
@javanna javanna added a commit to javanna/elasticsearch that referenced this issue
@javanna javanna Finalized support for aliases in index templates
- adapted existing PR to updated code (post #4920)
- resolved TODOs (bw compatible serialization etc.)
- added more tests
- added docs

Closes #1825
32cb732
@javanna javanna added a commit to javanna/elasticsearch that referenced this issue
@javanna javanna Finalized support for aliases in index templates
- adapted existing PR to updated code (post #4920)
- resolved TODOs (bw compatible serialization etc.)
- added more tests
- added docs

Closes #1825
9d074ad
@javanna javanna added a commit to javanna/elasticsearch that referenced this issue
@javanna javanna Finalized support for aliases in index templates
- adapted existing PR to updated code (post #4920)
- resolved TODOs (bw compatible serialization etc.)
- added more tests
- added docs

Closes #1825
bfd8899
@javanna javanna added a commit to javanna/elasticsearch that referenced this issue
@javanna javanna Finalized support for aliases in index templates
- adapted existing PR to updated code (post #4920)
- resolved TODOs (bw compatible serialization etc.)
- added more tests
- added docs

Closes #1825
6ff74f8
@javanna javanna added a commit to javanna/elasticsearch that referenced this issue
@javanna javanna Finalized support for aliases in index templates
- adapted existing PR to updated code (post #4920)
- resolved TODOs (bw compatible serialization etc.)
- added more tests
- added docs

Closes #1825
a2fdb1f
@javanna javanna added a commit to javanna/elasticsearch that referenced this issue
@jbrook jbrook Added support for aliases to index templates
Adapted existing PR (#2739) to updated code (post #4920), added tests and docs (@javanna)

Closes #1825
d302983
@javanna javanna added a commit that closed this issue
@jbrook jbrook Added support for aliases to index templates
Adapted existing PR (#2739) to updated code (post #4920), added tests and docs (@javanna)

Closes #1825
a93d6d5
@javanna javanna closed this in a93d6d5
@javanna javanna added a commit that referenced this issue
@jbrook jbrook Added support for aliases to index templates
Adapted existing PR (#2739) to updated code (post #4920), added tests and docs (@javanna)

Closes #1825
5ebabd9
@rbraley

This is great, but would it be possible to specify a different pattern than just "{index}-alias" in the alias name? I have a use case where I have an index per day with the date after it: "index_name_20140306" and I want to add it to an alias "index_name" to group them all together for searching.

Can we make the alias name a script field so we can use mvel to calculate the alias name? Or perhaps add more things we can use like the value of a field defined on a template's mapping? "{field.path}" perhaps similar to how we can define routing by the value of a field?

@javanna
elastic member

Hi @rbraley we had the same discussion in #5180 and decided to merge the PR in as is since we didn't reach a consensus on how to support what you (and other users too) are asking for. On the other hand, we can always improve this, would you mind opening a new specific issue for this?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Something went wrong with that request. Please try again.