Search history in Elasticsearch


#1

Hi,

Have someone ever tried to implement a "search history" on top of Elasticsearch (or are there existing open source solutions)? In fact, what I want to do is to implement a component that will store the search history for each user. User could then see again the results of some queries he made before, and could also combine them (for example, the user can do an intersection of the result sets of two queries that are in his search history).
Do you have any advice on the best way to implement this component?

Thank you,


(Mark Walkom) #2

I haven't seen anything beyond people storing such things in a access log via a proxy which is a very round about way of doing it, but it's an interesting idea :slight_smile:


(Wheredevel) #3

Are you talking about a special index for storing all the inbound queries for a given index?
Or just offloading all the inbound queries to somewhere else...?

In any case, such feature would be very useful - see Google Search Autocompletion for example.
If it doesn't exist yet +1000 to have it!


#4

Sorry for the delay. The idea is to store the history "somewhere", but yes we should consider an ES indice . The idea beyond that for our use case is to be able to perform some analysis on it (such as top searched terms), but also to make the user able to search its last queries. Query suggestion based on previous search is also a possibility . So yes I thing an ES indice is a good candidate for that.


(system) #5