I am working on a web application for getting people together by
making it easy to create and discover events, and we'd like to
recommend events using elastic search. Events that are attended by
friends and/or friends of friends should show up with a higher
relevancy. We are currently not sure how to best query for this.
This is pseudo code for our data model:
user
- has many users as friends ( a single array of id's)
event
- has many users as attendees (a single array of id's)
We are getting friend data from Facebook so there are going to be many
more friends and friends of friends than events.
Any tips on how to create a query that lists upcoming events,
returning events attended by friends and/or friends of friends with a
higher relevancy, is greatly appreciated.
Best,
Andy