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

Add support for templates index_patternsfield in ES >= 6.0 #4056

Merged
merged 1 commit into from
Apr 20, 2017

Conversation

exekias
Copy link
Contributor

@exekias exekias commented Apr 19, 2017

The change was introduced in
elastic/elasticsearch#21009 and deprecates
old template field.

This change uses the new index_patterns field and keeps
compatibility with template for older version

closes #3133

Copy link
Member

@ruflin ruflin left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM. I suggest to add a changelog entry for this one.

"template": t.GetName() + "-*",
}

// ES 6 moved from template to index_patterns: https://github.com/elastic/elasticsearch/pull/21009
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Nice to have the link to the github issue here. makes it easy to track the change later again.

}

// ES 6 moved from template to index_patterns: https://github.com/elastic/elasticsearch/pull/21009
if t.esVersion.major >= 6 {
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

We should probably enhance version in the future to also support GreaterThenfunctions or similar. This will do for the moment.

The change was introduced in
elastic/elasticsearch#21009 and deprecates
old `template` field.

This change uses the new `index_patterns` field and keeps
compatibility with `template` for older version
@exekias
Copy link
Contributor Author

exekias commented Apr 20, 2017

jenkins, retest this please

@ruflin ruflin merged commit 607c69b into elastic:master Apr 20, 2017
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Change template to index-patterns in index template
2 participants