Hybrid MySQL-MongoDB Social DB

Job ID: 39805854

Budget: €8 – €30 EUR

I’m building a social-media platform and have decided on a hybrid data layer that combines MySQL for highly structured tables and MongoDB for flexible, evolving documents. The core data to model centres on user profiles and their interactions—everything from account details and privacy settings to follows, likes, and other engagement signals.

The job breaks down into three tightly-connected parts:

• Schema & Collection Design
‑ A relational schema in MySQL covering users, relationships, and interaction metrics.
‑ Complementary MongoDB collections to store activity feeds, preference blobs, and any future semi-structured payloads.

• Queries & Access Patterns
‑ Write representative SQL (joins, aggregates, indexed search) and MongoDB queries (aggregation pipeline, text search) that power timeline assembly, profile look-ups, and interaction counts.
‑ Include sample seed data so the queries can be run and demonstrated immediately.

• Performance & Documentation
‑ Index recommendations, sharding or partition notes, and caching guidance for both engines.
‑ A concise technical document that explains the design rationale, ER diagram / JSON schema, query examples, and benchmarks comparing alternative approaches.

Acceptance is straightforward: I’ll run the scripts on clean MySQL and MongoDB instances, execute the documented queries, and review the performance notes. If everything works and the documentation reads clearly, the job is done.