Largest graph network
Sometimes your data may include graph relationships between records within a single collection. Take, for instance, a document management system database that houses whitepapers citing other whitepapers within the same collection. Visualizing the chain of dependencies becomes crucial in such situations. This example shows how you can traverse these sorts of relationships within a collection.
Scenario
Your organization wants to know the best targets for a new marketing campaign based on a social network database such as Twitter.
You want to search the collection of social network users, each holding a user's name and the names of others who follow them. You want to traverse each user record's followed_by
array to determine which user has the most extensive network reach.
Note
This example uses a simple data model for brevity. However, this is unlikely to be an optimum data model for using $graphLookup
at scale for social network users with...