Hello,
My initial post ended up subjectless which is hard to follow.
http://elasticsearch-users.115913.n3.nabble.com/no-subject-td3136838.html
So I am repeating the use case in a separate thread.
Percolator response includes only names of the queries that matched are returned.
Use case is to add meta-data like fields (e.g. owner of the query) to the registered queries. And retrieve those fields in the percolator response and take some action according to their values.
If there is not a workaround for this, what do you think adding an option to return field values in Percolator response?
For example, the following command would return name of the mathced query (kuku) and value of the color field (green), in the percolator response.
curl -XGET localhost:9200/test/type1/_percolate?fields=color -d '{
"doc" : {
"field1" : "value1"
}
}'
P.S. Currently I am issuing an extra second query to percolator index to retive field values:
curl -XGET 'localhost:9200/_percolator/myindex/kuku?pretty=true&fields=color'
Thanks,
Ahmet