Modeling follow relationships

A data model for follow relationships should be able to answer two questions on behalf of a user:

  • Who do I follow?
  • Who follows me?

In Chapter 3, Organizing Related Data, you learned to design our table structures so that all important data access can be accomplished by querying a single partition. For this reason, we're better off considering the aforementioned questions separately and designing the right table schema for each.

Get Learning Apache Cassandra - Second Edition now with the O’Reilly learning platform.

O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.