WT-5479, when sweep is running frequently and closing handles it needs to acquire the dhandle lock for writing. When checkpoint is running in the gathering handles phase it holds the schema lock and needs to hold the dhandle lock for reading. Sweep can interfere with that checkpoint operation resulting in holding the schema lock longer. Since sweep is a background non-time critical operation, we should avoid grabbing that lock for writing if gathering handles is in progress.
- is related to
WT-5479 Checkpoint schema lock can cause long stalls in command execution on systems with many active data handles