See which API endpoint caused every bad MongoDB query
Atlas Advisor tells you that your database is running slow COLLSCAN queries, but it cannot map that slow query back to the originating codebase. TraceMole bridges this gap by tagging explain logs with API OpenTelemetry traces.
Why TraceMole is Different
Atlas tracks metrics at the database engine layer. TraceMole monitors at the application driver layer, mapping queries directly to HTTP routes, request headers, and execution files.
Aggregate explain plan telemery from Next.js APIs, Node.js cron tasks, and Python services querying a shared database cluster, in one unified view.
How TraceMole detects COLLSCANs
Native MongoDB Atlas database metrics are captured at the database server engine layer, flagging slow collection scans only after they occur. TraceMole listens directly to application-layer database driver queries in real-time. This allows us to intercept slow MongoDB executions and trigger asynchronous explain plan analysis, identifying COLLSCAN stages immediately.
Why MongoDB queries become slow
Without correct index coverage matching your query query patterns, MongoDB performs linear scans, loading every record in a collection from disk. This consumes massive CPU and IOPS bandwidth, slowing down concurrent requests. While Atlas Performance Advisor tells you that your database is slow, TraceMole provides the application-level execution path tracing, showing exactly which API routes and code blocks initiated those unindexed queries.
Feature Comparison Matrix
| Diagnostic Metric | Atlas Advisor | TraceMole |
|---|---|---|
| Detect COLLSCAN & query warnings | ✓ Yes | ✓ Yes |
| Compound index suggestions | ✓ Yes | ✓ Yes |
| Link queries to HTTP request traces | ✗ No | ✓ Yes |
| Identify query originating code files | ✗ No | ✓ Yes |