We noticed that Grade needsupdate code in Latest 2.8 fails with large recordset. We have a client which has a single course having 2m records. All other courses went fine with needsupdate code but that one course stuck.
Problem is that for various reasons (timeouts, memory etc) it is not practical to execute this amount of processing on browser.
Workaround: We created a cli script and executed it via shell.
Solution: It would be better to push similar code in cron.