# Percolator usage confusion

**URL:** https://discuss.elastic.co/t/percolator-usage-confusion/5846
**Category:** Elasticsearch
**Created:** [November 11, 2011, 5:22pm UTC](https://discuss.elastic.co/t/percolator-usage-confusion/5846 "2011-11-11T17:22:42Z")
**Posts on this page:** 3
**Page:** 1

<div class="post-metadata">

### Author: ![Mauricio\_Alarcon](https://avatars.discourse-cdn.com/v4/letter/m/cab0a1/32.png) [@Mauricio\_Alarcon](https://discuss.elastic.co/u/Mauricio_Alarcon)
#### Post date: [November 11, 2011, 5:22pm UTC](https://discuss.elastic.co/t/percolator-usage-confusion/5846/1 "2011-11-11T17:22:42Z")

</div>

I'm a bit confused about the use of percolator, I've got a use case  
that I think it might apply, but after playing with it for a while I  
can't figure out if that's the best match. I was wondering if someone  
can give me insights about this

I'm planning to use as part of an "alerts" system we need to  
implement, thus, if a new "document" matching the user query is  
inserted, then we'll proceed to email the user with the latest  
results.

For the sake of simplification, let's say I've got a index with  
"books" as documents (title, author, print date, isbn, etc), then  
users register for an alert, e.g. "author = John Doe,  
since=2011-11-10".

During the day a lot of new books are inserted in the index. Can I use  
the percolator to know out of the new inserted books which one needs  
to be send as alerts?

Reading the documentation seems that I need to apply the percolator  
function to each inserted document. Is there a way to use percolator  
as a means to get me all the queries we need to run to alert the  
users?

Thanks

~M

---

<div class="post-metadata">

### Author: ![kimchy](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/kimchy/32/44952_2.png) [@kimchy](https://discuss.elastic.co/u/kimchy)
#### Post date: [November 13, 2011, 8:46am UTC](https://discuss.elastic.co/t/percolator-usage-confusion/5846/2 "2011-11-13T08:46:34Z")

</div>

Percolate will return matching queries when you index a document. You can  
potentially simply implement the alerts by executing scheduled queries if  
it fits your use case better.

On Fri, Nov 11, 2011 at 7:22 PM, maverick [mauricio.alarcon@gmail.com](mailto:mauricio.alarcon@gmail.com)wrote:

> I'm a bit confused about the use of percolator, I've got a use case  
> that I think it might apply, but after playing with it for a while I  
> can't figure out if that's the best match. I was wondering if someone  
> can give me insights about this
> 
> I'm planning to use as part of an "alerts" system we need to  
> implement, thus, if a new "document" matching the user query is  
> inserted, then we'll proceed to email the user with the latest  
> results.
> 
> For the sake of simplification, let's say I've got a index with  
> "books" as documents (title, author, print date, isbn, etc), then  
> users register for an alert, e.g. "author = John Doe,  
> since=2011-11-10".
> 
> During the day a lot of new books are inserted in the index. Can I use  
> the percolator to know out of the new inserted books which one needs  
> to be send as alerts?
> 
> Reading the documentation seems that I need to apply the percolator  
> function to each inserted document. Is there a way to use percolator  
> as a means to get me all the queries we need to run to alert the  
> users?
> 
> Thanks
> 
> ~M

---

<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 6, 2017, 3:48am UTC](https://discuss.elastic.co/t/percolator-usage-confusion/5846/3 "2017-07-06T03:48:53Z")

</div>


