MongoDB Expert — Optimize Slow Queries/Aggregations on Production Atlas (M20, no tier upgrade)

Posted 2 weeks ago

Worldwide

Summary

MongoDB Atlas Performance Optimization — Production (M20, ~30 GB) ▎ We run a production SaaS backend on MongoDB Atlas (replica set, M20 tier, ~30 GB dataset). Backend is Java / Spring Boot microservices using Spring Data MongoDB. Under load we see slow queries ▎ and heavy aggregations, occasional CPU spikes and brief replica-set elections, and some list/search endpoints that take minutes instead of milliseconds. ▎ Important: we want to stay on the M20 tier — the goal is to optimize queries, indexes, and configuration to fit within current resources, not to scale up hardware. We'll only consider a tier ▎ change as a last resort. Scope of work ▎ - Identify the slowest/most expensive operations using Atlas Profiler, Performance Advisor, and server logs. ▎ - Analyze with explain(); design and implement targeted compound indexes. ▎ - Optimize heavy aggregation pipelines — e.g. a paginated listing endpoint that does a $lookup over a large (millions of docs) collection then filters post-join, and an unindexed regex/text ▎ search that scans the collection. Recommend the right approach (index, pipeline restructure, or Atlas Search where justified). ▎ - Add query time-bounds (maxTimeMS) and tune client connection pool sizes + socket timeouts so a runaway query can't pin the cluster. ▎ - Reduce working-set / WiredTiger cache pressure so hot data fits in M20 RAM. ▎ - Advise on data retention/archival for bloated collections. ▎ - Set up alerts (CPU, slow ops, connections, primary elections) and a short runbook. Deliverables ▎ - Prioritized findings report (with explain() evidence). ▎ - Implemented/recommended index + query changes with before/after metrics (latency, docs examined, CPU). ▎ - Connection-pool / timeout / retention recommendations. ▎ - Brief documentation + monitoring/alert setup. Required skills ▎ - Deep MongoDB internals + Atlas experience (replica sets, WiredTiger cache, oplog). ▎ - Proven aggregation-pipeline optimization and indexing strategy (compound indexes, ESR rule, covered queries). ▎ - Comfortable reading explain() plans and Atlas metrics. ▎ - Spring Data MongoDB familiarity is a strong plus (so fixes map cleanly to our code).

  • $100.00

    Fixed-price
  • Intermediate
    Experience Level
  • Remote Job
  • One-time project
    Project Type
Skills and Expertise
Mandatory skills
MongoDB
Node.js
Java
Activity on this job
  • Proposals:5 to 10
  • Interviewing:
    0
  • Invites sent:
    0
  • Unanswered invites:
    0
About the client
Member since May 15, 2017
  • India
    Bhubaneswar11:15 PM
  • $1.8K total spent
    36 hires, 1 active
  • 100 hours
  • Finance & Accounting
    Small company (2-9 people)

Explore similar jobs on Upwork

Build model driven app togetherHourly‐ Posted 3 weeks ago
Symfonia data migration to Systim
New
Hourly‐ Posted 6 hours ago
Database Administration
Database Design
Data Migration
SQL
Data Integration

How it works

  • Post a job icon
    Create your free profile
    Highlight your skills and experience, show your portfolio, and set your ideal pay rate.
  • Talent comes to you icon
    Work the way you want
    Apply for jobs, create easy-to-by projects, or access exclusive opportunities that come to you.
  • Payment simplified icon
    Get paid securely
    From contract to payment, we help you work safely and get paid securely.
Want to get started? Create a profile

About Upwork

  • Rating is 4.9 out of 5.
    4.9/5
    (Average rating of clients by professionals)
  • G2 2021
    #1 freelance platform
  • 49,000+
    Signed contract every week
  • $2.3B
    Freelancers earned on Upwork in 2020

Find the best freelance jobs

Growing your career is as easy as creating a free profile and finding work like this that fits your skills.

Trusted by

  • Microsoft Logo
  • Airbnb Logo
  • Bissell Logo
  • GoDaddy Logo