[SERVER-81192] Introduce background maintenance task queue Created: 19/Sep/23  Updated: 03/Jan/24  Resolved: 02/Jan/24

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

Type: Improvement Priority: Major - P3
Reporter: Dan Larkin-York Assignee: Daotang Yang
Resolution: Won't Fix Votes: 0
Labels: None
Remaining Estimate: Not Specified
Time Spent: Not Specified
Original Estimate: Not Specified

Issue Links:
Related
is related to SERVER-80978 Fix potential deadlock between TTLMon... Closed
is related to SERVER-77828 listIndexes should report expireAfter... Closed
Assigned Teams:
Storage Execution
Sprint: Execution Team 2023-12-25, Execution Team 2024-01-08
Participants:

 Description   

We occasionally have infrequent or one-off background maintenance tasks we wish to run in the server. Currently we typically need to register these with some existing service that runs periodically and requires that service to check whether we have any such tasks waiting. Alternatively we sometimes create a new background service for each such type of task (a dedicated thread, either raw or via PeriodicJobRunner), which runs into issues of thread proliferation.

As an alternative, we can create a general-purpose task queue that processes these infrequent tasks when they come available.

At least to begin with, the queue will be focused on processing light-weight tasks, and is not meant to replace any existing thread pools that we use for heavy processing (e.g. index builds).


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