Error when creating a index template for a Time Serie

Hello,

I'm trying to use a timeserie datastream, for that I try to create an index template, note that
the bellow example it is almost the same as the one in the documentation:

PUT _index_template/my-weather-sensor-index-template
{
  "index_patterns": ["metrics-weather_sensors-*"],
  "data_stream": { },
  "template": {
    "settings": {
      "index.mode": "time_series"
    }
  },
  "priority": 500,
  "_meta": {
    "description": "Template for my weather sensor data"
  }
}

But I get an error:

{
  "error" : {
    "root_cause" : [
      {
        "type" : "invalid_index_template_exception",
        "reason" : "index_template [my-weather-sensor-index-template] invalid, cause [Validation Failed: 1: unknown setting [index.mode] did you mean [index.codec]?;]"
      }
    ],
    "type" : "invalid_index_template_exception",
    "reason" : "index_template [my-weather-sensor-index-template] invalid, cause [Validation Failed: 1: unknown setting [index.mode] did you mean [index.codec]?;]"
  },
  "status" : 400
}

I don't understand why, I would appreacite any idea/help.

Thanks.

What version of Elasticsearch are you using?

thanks, mmm I see 7.16.1 and that looks that is the reason

Yeah, TSDS started on version 8.5.

The documentation you shared is for version 8.10, not 8.1.

In the Elastic documentation site you can change on the left side to look at the documentation for a specific version, if you change it between version 8 minor releases you will see that the page only exists from version 8.5

Since you are on version 7.16, you would need to upgrade to version 7.17 and then you could upgrade to version 8.10.

Sorry that was a typo, I see it here the feature was released in that version, thanks.

I have few other doubts: I see that the documentation examples of TSDS use a policy that enables searchable snapshoots, are they required to reach the mentioned 70% compression ? Are they necessary for using TSDS?

Regards.

I'm not sure I do not use TSDS nor have plan to use it, and Searchable Snapshots are only available with a paid Enterprise License, which I also do not have.

But you do not need to have searchable snapshots to use TSDS and the mentioned compression is also not related to it, basically all policies will have a searchable snapshot phase.

OK, in the documentation it is not mentioned that searchable snapshoots are required, on the other side I see having the policies does not require to have a searchable snapshoot phase but would be logical to have it.

Also I never have used them, I'll go for the version update.

Thanks.

This topic was automatically closed 28 days after the last reply. New replies are no longer allowed.