We had some performance issues today, and I narrowed it down to it being the Moodle cron taking forever to run.
It seemed to get stuck at the processing events queue, as it had so many events to process. I had a look in the events_queue table and there were over 1 million records in there, dating back over 2 years.
Should those records not have been wiped after they had been processed? Would it have been trying to do all of them every time?