View Issue Details
ID | Project | Category | View Status | Date Submitted | Last Update |
---|---|---|---|---|---|
0005656 | Composr | core | public | 2024-03-30 23:57 | 2024-07-23 16:56 |
Reporter | Patrick Schmalstig | Assigned To | Patrick Schmalstig | ||
Severity | Feature-request | ||||
Status | resolved | Resolution | fixed | ||
Product Version | |||||
Fixed in Version | |||||
Summary | 0005656: Optimise task queue more intelligently | ||||
Description | Due to a memory issue if the task queue got populated too much, I implemented a temporary fix by limiting to 50 tasks per Cron cycle. Let's make this more intelligent because not every task demands the same resources as other tasks, so we could intelligently fluctuate the number of tasks we run on a cycle depending on what tasks there are to run. Let's track time. Process each task one at a time instead of locking a set number of tasks at once. After each task finishes, check how much time we spent so far processing background tasks. Once we reach, say, 15 seconds, then stop there for this Cron cycle. We could make this a config option as well for specifying how long to spend max on the task queue for each Cron cycle. | ||||
Tags | Roadmap: v11 | ||||
Time estimation (hours) | |||||
Sponsorship open | |||||
related to | 0003958 | non-assigned | Opportunistic scheduler | |
related to | 0005586 | assigned | Patrick Schmalstig | Task queue: Cron does not respect number of locked tasks; maybe it should |
|
I decided on 10 seconds or 3,900 total database queries so far for the Cron run |
|
Ideally this method should be replaced by 0003958 in the future; this is a good temporary solution IMO until we can code in the more complex one. The major drawback is this one just runs tasks in hook order, so higher hooks have higher priority. |
Date Modified | Username | Field | Change |
---|---|---|---|
2024-03-30 23:57 | Patrick Schmalstig | New Issue | |
2024-03-30 23:57 | Patrick Schmalstig | Status | non-assigned => assigned |
2024-03-30 23:57 | Patrick Schmalstig | Assigned To | => Patrick Schmalstig |
2024-03-30 23:57 | Patrick Schmalstig | Tag Attached: Roadmap: v11 | |
2024-04-12 19:00 | Patrick Schmalstig | Status | assigned => resolved |
2024-04-12 19:00 | Patrick Schmalstig | Resolution | open => fixed |
2024-04-14 23:50 | Patrick Schmalstig | Note Added: 0008593 | |
2024-07-23 14:57 | Chris Graham | Relationship added | related to 0003958 |
2024-07-23 15:03 | Chris Graham | Relationship added | related to 0005586 |
2024-07-23 16:55 | Patrick Schmalstig | Note Added: 0008896 | |
2024-07-23 16:55 | Patrick Schmalstig | Note Edited: 0008896 | View Revisions |
2024-07-23 16:56 | Patrick Schmalstig | Note Edited: 0008896 | View Revisions |