# Regarding the implementation of \_ttl

**URL:** <https://discuss.elastic.co/t/regarding-the-implementation-of--ttl/36875>\
**Category:** Elasticsearch\
**Created:** [December 10, 2015, 12:19pm UTC](https://discuss.elastic.co/t/regarding-the-implementation-of--ttl/36875 "2015-12-10T12:19:22Z")\
**Posts on this page:** 4\
**Page:** 1

<div class="post-metadata">

**Author:** ![S.Hlawa](https://avatars.discourse-cdn.com/v4/letter/s/e19adc/32.png) [@S.Hlawa](https://discuss.elastic.co/u/S.Hlawa)\
**Post date:** [December 10, 2015, 12:19pm UTC](https://discuss.elastic.co/t/regarding-the-implementation-of--ttl/36875/1 "2015-12-10T12:19:22Z")

</div>

Hello all,

I've got a small question regarding the implementation of the \_ttl field.

It is written in the docs that

> The current \_ttl implementation is deprecated and will be replaced with a different implementation in a future version.

Will the usage of the field be changed too? And when is the estimated time these changes will be impelmented?

Best regards,

S.Hlawa

---

<div class="post-metadata">

**Author:** ![mainec](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/mainec/32/5557_2.png) [@mainec](https://discuss.elastic.co/u/mainec)\
**Post date:** [December 10, 2015, 1:01pm UTC](https://discuss.elastic.co/t/regarding-the-implementation-of--ttl/36875/2 "2015-12-10T13:01:18Z")

</div>

> [@S.Hlawa](#):
>
> Will the usage of the field be changed too? And when is the estimated time these changes will be impelmented?

The migration guide might be helpful for you: [https://www.elastic.co/guide/en/elasticsearch/reference/current/breaking\_20\_mapping\_changes.html#\_literal\_\_timestamp\_literal\_and\_literal\_\_ttl\_literal\_deprecated](https://www.elastic.co/guide/en/elasticsearch/reference/current/breaking_20_mapping_changes.html#_literal __timestamp_literal_and_literal__ ttl_literal_deprecated)

Quoting said guide: "The \_timestamp and \_ttl fields are deprecated, but will remain functional for the remainder of the 2.x series.

Instead of the \_timestamp field, use a normal date field and set the value explicitly.

The current \_ttl functionality will be replaced in a future version with a new implementation of TTL, possibly with different semantics, and will not depend on the \_timestamp field."

Hope this helps,  
Isabel

---

<div class="post-metadata">

**Author:** ![warkolm](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/warkolm/32/39224_2.png) [@warkolm](https://discuss.elastic.co/u/warkolm)\
**Post date:** [December 12, 2015, 12:54am UTC](https://discuss.elastic.co/t/regarding-the-implementation-of--ttl/36875/3 "2015-12-12T00:54:15Z")

</div>

You can/should use time based indices instead.

---

<div class="post-metadata">

**Author:** ![system](https://us1.discourse-cdn.com/elastic/original/3X/1/a/1ac57faf039f6b580b3f104ef42a2a89e41014de.png) [@system](https://discuss.elastic.co/u/system)\
**Post date:** [July 5, 2017, 11:31pm UTC](https://discuss.elastic.co/t/regarding-the-implementation-of--ttl/36875/4 "2017-07-05T23:31:36Z")

</div>


