[SERVER-38481] Profiling should not hold strong locks while it's uninterruptible Created: 07/Dec/18  Updated: 29/Oct/23  Resolved: 08/Jan/19

Status: Closed
Project: Core Server
Component/s: Diagnostics, Replication
Affects Version/s: None
Fix Version/s: 4.1.7

Type: Task Priority: Major - P3
Reporter: Siyuan Zhou Assignee: Justin Seyster
Resolution: Fixed Votes: 0
Labels: prepare_interruptibility
Remaining Estimate: Not Specified
Time Spent: Not Specified
Original Estimate: Not Specified

Issue Links:
Problem/Incident
Backwards Compatibility: Fully Compatible
Sprint: Query 2019-01-14
Participants:
Linked BF Score: 0

 Description   

Profiling are uninterruptible, but it can acquire DB X lock if the profiling collection is missing so the collection will be created on the fly. That will conflict with prepared transactions on that database.



 Comments   
Comment by Githook User [ 11/Jan/19 ]

Author:

{'username': 'jseyster', 'email': 'justin.seyster@mongodb.com', 'name': 'Justin Seyster'}

Message: SERVER-38481 Mark profile_interrupted_op.js as "requires_profiling"
Branch: master
https://github.com/mongodb/mongo/commit/f578f7ab587663d1b50dbd87854fba023e33d1ec

Comment by Githook User [ 08/Jan/19 ]

Author:

{'username': 'jseyster', 'email': 'justin.seyster@mongodb.com', 'name': 'Justin Seyster'}

Message: SERVER-38481 No strong locks in profiling while uninterruptible
Branch: master
https://github.com/mongodb/mongo/commit/e2b8d928d796b4b6a6144bc4aa27db6fe95bfdd8

Comment by Craig Homa [ 17/Dec/18 ]

Moving to the Query backlog to triage.

Comment by Eric Milkie [ 11/Dec/18 ]

Since acquiring a DB X lock is very rare, I think we can just make that particular lock acquisition interruptible. If we miss a profilable operation because it was interrupted AND we needed to create the profiling collection, I think that's okay.

Generated at Thu Feb 08 04:49:04 UTC 2024 using Jira 9.7.1#970001-sha1:2222b88b221c4928ef0de3161136cc90c8356a66.