Understand the NewsBlur Data Architecture
mainNewsBlur utilizes a multi-database strategy to handle different data types efficiently:
- PostgreSQL: Stores relational data requiring ACID guarantees, such as user accounts, feed metadata, subscriptions, recommendations, OAuth tokens, and payment records.
- MongoDB: Handles high-volume document storage with flexible schemas, including stories (
MStory), starred stories, read states, classifiers, social data, AI responses, and briefings. - Redis: Acts as an in-memory cache, message broker, and session store. It manages user data cache, analytics, statistics, Celery brokers, Django cache, and session state.
- Elasticsearch: Powers full-text search and vector-based discovery for feeds (
SearchFeed) and stories (SearchStory,DiscoverStory).