e-Book - Redis in Action

This book covers the use of Redis, an in-memory database/data structure server.
  • Foreword
  • Preface
  • Acknowledgments
  • About this Book
  • About the Cover Illustration
  • Part 1: Getting Started
  • Part 2: Core concepts
  • Part 3: Next steps
  • Appendix A
  • Appendix B
  • Buy the paperback

    8.1 Users and statuses

    As users interact with Twitter, two types of objects hold the most important information:
    users and status messages. User objects hold basic identity information, as well as
    aggregate data about the number of followers, number of status messages posted, and
    more. The user objects are important because they’re the starting point for every
    other kind of data that’s available or interesting. Status messages are also important
    because they’re how individuals express themselves and interact with each other, and
    are the true content of social networks.

    In this section, we’ll talk about what data will be stored in the user and status message
    objects and how we’ll store them. We’ll also look at a function to create a new

    Our first step is to define and create the structure for a user.