-
Notifications
You must be signed in to change notification settings - Fork 25.1k
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
Percolators: Support delete-by-query #1712
Comments
Can't say I tested deleting the percolator index itself but I have run across this issue when deleting _percolator queries by query rather than by id. |
I have encountered this bug too. |
+1, encountered it too. |
+1, encountered it too. We create the percolators each night anew during re-indexing. It would be great if we could just delete the _percolator index in order to delete all percolators. This doesn't work, as described above. Instead, our workaround is:
That's neither elegant nor efficient, but it works so far. |
+1, also experiencing this issue. |
Same problem here. The index as the type of the index deleting does nothing. |
The workaround doesn't work for me. Searching for percolator documents yields nothing:
But then percolating a document yields results...
Not sure how to get out of this state as deleting the _percolator index does nothing. I'm using Elasticsearch 0.20.6. |
Deleting a type from the percolator index via
internally issues a delete-by query, which succeeds, but does not update the registered percolator queries. This is the reason for both failing at the moment. |
So, once a percolator has been "deleted" the wrong way, it's stuck forever in the system? Is there any solution to work around this issue ? Or do I have to start over on a clean setup ? |
Restarting the cluster is a temporary solution. On Thu, Aug 1, 2013 at 9:26 AM, Jimmy Thomas [email protected]:
adamgeorgiou.com |
Oh yes, thanks ! Recreating the percolators and deleting them one by one also worked. |
When a type is being deleted, under the hood a delete by query is executed to delete all document that have the type you are deleting. Unfortunately the percolator doesn't support delete by query (only normal deletes) and therefore the loaded queries aren't updated. |
When will the percolator support delete by query? |
In order to update the percolator queries in realtime when a delete by query gets executed, the delete by query needs to be implemented differently. Not sure when this will be done. The new percolator in master (soon to be 1.0 beta1), does update the in memory percolate queries in realtime when a percolate index or the |
The old percolator has been removed. Closing |
I can still reproduce this problem with the new percolator on v1.2.1. The registered percolators are stuck in the registry, even after issuing a delete query. curl -XPUT 'localhost:9200/my-index/.percolator/1' -d '{
"query" : {
"match" : {
"message" : "bonsai tree"
}
}
}' At this point, the following returns '1' in the hits: curl -XGET 'localhost:9200/my-index/.percolator/_search' -d '{
"query" : {
"match_all" : {}
}
}' After issuing a delete all query, the percolator no longer shows up in the search: curl -XDELETE 'localhost:9200/my-index/.percolator/_query' -d '{
"query" : {
"match_all" : {}
}
}'
However, the percolator continues to show up as a result in percolate runs. The following returns the percolator with id '1':
|
Yeah sorry - closed this without testing. Delete by query doesn't work with percolators: http://www.elasticsearch.org/guide/en/elasticsearch/reference/current/search-percolate.html#_important_notes I'll reopen |
Blocked by #2230 |
Closing in favour of #7052 |
has there been a fix proposed for this, or just to avoid deleting percolators with a filter query? version: { |
The error doesn't happen when I delete the queries one by one.
It only happens when you delete the percolator index itself for a index.
Gist for reproducing the error:
https://gist.github.com/1678150
The text was updated successfully, but these errors were encountered: