Duplicate entries in the message_delete queue

Created on 31 July 2025, 2 days ago

Problem/Motivation

We used this module in a website where a lot of users and contents exist, resulting in a heavy usage of message entities and templates for in-site notifications and emails.

Cron is executed every 5 minutes by the hosting company. The same schedule exists for the processing of the queue items. Due to the heavy usage though, the messages are added to the "message_delete" queue multiple times before being actually deleted. Until this was discovered, the queue table had been occupying 40GB of data.

Proposed resolution

Option a: Find a way to stop bloating the queue. Maybe an extra column to mark a message as queued so that we don't re-add it to the queue?
Option b: Just document in a project description and in README.md that the default message_cron() implementation shouldn't be executed frequently in a website with a high usage of message entities; suggest using ultimate_cron with proper schedule time.

User interface changes

None.

API changes

None.

Data model changes

None.

🐛 Bug report
Status

Active

Version

1.0

Component

Code

Created by

🇬🇷Greece vensires

Live updates comments and jobs are added and updated live.
Sign in to follow issues

Comments & Activities

Production build 0.71.5 2024