# Curator & Knowing when documents have been unIndexed

**URL:** <https://discuss.elastic.co/t/curator-knowing-when-documents-have-been-unindexed/136498>\
**Category:** Elasticsearch\
**Created:** [June 19, 2018, 1:15pm UTC](https://discuss.elastic.co/t/curator-knowing-when-documents-have-been-unindexed/136498 "2018-06-19T13:15:45Z")\
**Posts on this page:** 8\
**Page:** 1

<div class="post-metadata">

**Author:** ![GazD](https://avatars.discourse-cdn.com/v4/letter/g/49beb7/32.png) [@GazD](https://discuss.elastic.co/u/GazD)\
**Post date:** [June 19, 2018, 1:15pm UTC](https://discuss.elastic.co/t/curator-knowing-when-documents-have-been-unindexed/136498/1 "2018-06-19T13:15:45Z")

</div>

Is there any way of being notified about this or any way to find out?

---

<div class="post-metadata">

**Author:** ![theuntergeek](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/theuntergeek/32/44961_2.png) [@theuntergeek](https://discuss.elastic.co/u/theuntergeek)\
**Post date:** [June 19, 2018, 1:27pm UTC](https://discuss.elastic.co/t/curator-knowing-when-documents-have-been-unindexed/136498/2 "2018-06-19T13:27:10Z")

</div>

What do you mean by "unIndexed?" This term is not one I'm familiar with.

---

<div class="post-metadata">

**Author:** ![GazD](https://avatars.discourse-cdn.com/v4/letter/g/49beb7/32.png) [@GazD](https://discuss.elastic.co/u/GazD)\
**Post date:** [June 19, 2018, 1:32pm UTC](https://discuss.elastic.co/t/curator-knowing-when-documents-have-been-unindexed/136498/3 "2018-06-19T13:32:44Z")

</div>

Assume Curator is configured to delete, on a daily basis, documents that are over 30 days old. They get marked as such and once segments are merged, the documents are gone. No longer indexed. Unindexed (I will coin this term).

---

<div class="post-metadata">

**Author:** ![theuntergeek](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/theuntergeek/32/44961_2.png) [@theuntergeek](https://discuss.elastic.co/u/theuntergeek)\
**Post date:** [June 19, 2018, 2:05pm UTC](https://discuss.elastic.co/t/curator-knowing-when-documents-have-been-unindexed/136498/4 "2018-06-19T14:05:06Z")

</div>

Curator can only delete entire indices. If you need to delete documents from within an index, you should look into `delete_by_query`

---

<div class="post-metadata">

**Author:** ![GazD](https://avatars.discourse-cdn.com/v4/letter/g/49beb7/32.png) [@GazD](https://discuss.elastic.co/u/GazD)\
**Post date:** [June 19, 2018, 2:16pm UTC](https://discuss.elastic.co/t/curator-knowing-when-documents-have-been-unindexed/136498/5 "2018-06-19T14:16:32Z")

</div>

Yes I understand that, but surely the associated documents also get deleted right?

---

<div class="post-metadata">

**Author:** ![theuntergeek](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/theuntergeek/32/44961_2.png) [@theuntergeek](https://discuss.elastic.co/u/theuntergeek)\
**Post date:** [June 19, 2018, 2:45pm UTC](https://discuss.elastic.co/t/curator-knowing-when-documents-have-been-unindexed/136498/6 "2018-06-19T14:45:09Z")

</div>

Think of it like SQL. A document is a row, and an index a table. Drop the table, and all the rows go with it. They don't get "tagged" for deletion. There's not even a need for a segment merge. An index deletion in Elasticsearch is quick and permanent. The segment files are purged from the filesystem immediately, unless you have a very slow cluster/node, in which case it will do it as soon as it can.

---

<div class="post-metadata">

**Author:** ![GazD](https://avatars.discourse-cdn.com/v4/letter/g/49beb7/32.png) [@GazD](https://discuss.elastic.co/u/GazD)\
**Post date:** [June 19, 2018, 2:53pm UTC](https://discuss.elastic.co/t/curator-knowing-when-documents-have-been-unindexed/136498/7 "2018-06-19T14:53:11Z")

</div>

Ok I got you. Thanks

---

<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 17, 2018, 2:53pm UTC](https://discuss.elastic.co/t/curator-knowing-when-documents-have-been-unindexed/136498/8 "2018-07-17T14:53:14Z")

</div>

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