Design a Data Model for an Online Book Library
Design a data model for an online library system where users can browse books, make reservations, and leave reviews. You should consider scale and data access patterns, asking clarifying questions along the way. Topics include: schema design (relational or document-based), indexing trade-offs, full-text search support, and handling concurrent book reservations (e.g., using pessimistic locking or reservation-intent entities to prevent double-booking).
Asked at:
MongoDB