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 deprecation warning to Changelog and documentation for setup.template.type #28618

Merged
merged 4 commits into from
Oct 25, 2021
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
1 change: 1 addition & 0 deletions CHANGELOG.next.asciidoc
Original file line number Diff line number Diff line change
Expand Up @@ -550,6 +550,7 @@ to `legacy`. {pull}28538[28538]

*Affecting all Beats*

- Deprecate `setup.template.type`. In the future Beats will load data streams instead of regular indices.

*Filebeat*

Expand Down
8 changes: 6 additions & 2 deletions libbeat/docs/howto/load-index-templates.asciidoc
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@ lifecycle policy used to manage indices as they grow and age.

The recommended index template file for {beatname_uc} is installed by the
{beatname_uc} packages. If you accept the default configuration in the
+{beatname_lc}.yml+ config file, {beatname_uc} loads the template automatically
+{beatname_lc}.yml+ config file, {beatname_uc} loads the {ref}/index-templates.html[composable template] automatically
after successfully connecting to {es}. If the template already exists,
it's not overwritten unless you configure {beatname_uc} to do so.

Expand All @@ -33,7 +33,7 @@ For a full list of template setup options, see <<configuration-template>>.
[[load-custom-template]]
=== Load your own index template

To load your own index template, set the following options:
To load your own composable index template, set the following options:

[source,yaml]
-----
Expand All @@ -44,6 +44,10 @@ setup.template.fields: "path/to/fields.yml"
If the template already exists, it’s not overwritten unless you configure
{beatname_uc} to do so.

If your template is still in the legacy format, please set `setup.template.type` to
`legacy`. Please, convert your index template to the composable format, because
in the future support for legacy templates is going to be removed.

[float]
[[overwrite-template]]
=== Overwrite an existing index template
Expand Down
10 changes: 6 additions & 4 deletions libbeat/docs/template-config.asciidoc
Original file line number Diff line number Diff line change
Expand Up @@ -27,10 +27,12 @@ existing one.
you must <<load-template-manually,load the template manually>>.

ifndef::apm-server[]
*`setup.template.type`*:: The type of template to use. Available options: `legacy` (default), index templates
before Elasticsearch v7.8. Use this to avoid breaking existing deployments. New options are `component`
and `index`. Selecting `component` loads a component template which can be included in new index templates.
The option `index` loads the new index template.
*`setup.template.type`*:: Deprecated in 7.16. The type of template to use. The default value is `index`,
that loads {ref}/index-templates.html[index templates].
Further options: `legacy`, {ref}/indices-templates-v1.html[legacy index templates] before Elasticsearch v7.8.
Use this to avoid breaking existing deployments.
And `component`, selecting it loads a component template which can be included in index templates.
Copy link
Contributor

Choose a reason for hiding this comment

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

I think I'm still confused on what exactly the component template feature will do but this is not related to this PR.

Copy link
Contributor Author

Choose a reason for hiding this comment

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

The implementation is in #28538, this is the missing docs.

Regarding the component index template, no need to worry about it because it is going to be removed in 8.0.0 :)

The option `index` loads the new composable index template.
endif::[]

*`setup.template.name`*:: The name of the template. The default is
Expand Down