[SERVER-82865] Lightweight collection acquisition for findOneById Created: 07/Nov/23  Updated: 30/Nov/23

Status: Backlog
Project: Core Server
Component/s: None
Affects Version/s: None
Fix Version/s: None

Type: Improvement Priority: Major - P3
Reporter: Daniel Gomez Ferro Assignee: Backlog - Catalog and Routing
Resolution: Unresolved Votes: 0
Labels: perf-tiger, perf-tiger-handoff
Remaining Estimate: Not Specified
Time Spent: Not Specified
Original Estimate: Not Specified

Issue Links:
Related
is related to SERVER-81850 Use a more aggressive IDHACK for find... In Progress
Assigned Teams:
Catalog and Routing
Participants:

 Description   

PERF-4548 identified AutoGetCollection as one important source for findOneById regressions on 7.0. It's also one of the largest contributors to latency in absolute terms.

PERF-4741 created a POC with much simpler logic to acquire a collection for the specific case of findOneById, showing significant improvements for some workloads (e.g. 20% for ycsb_100read on top of PERF-4696).

The main changes of PERF-4741 are:

  • Not taking any global locks on the fast path, relying instead on a "hazard-pointer like" mechanism.
  • Doesn't canonicalize the query.
  • Doesn't instantiate AutoStatsTracker.
  • Doesn't take storage tickets on the fast path, it uses a rudimentary rate limiter based on a semaphore, it continues to take locks and tickets on the slow path.

Generated at Thu Feb 08 06:50:30 UTC 2024 using Jira 9.7.1#970001-sha1:2222b88b221c4928ef0de3161136cc90c8356a66.