Any specific reason for DB locking opposed to file?
That's like using DB for sessions ... some folks can run that way ... but many have switched to file.
Personally, I can see an advantage in file as opposed to DB in that nearly everything in moodledata will re-generate after manual removal of contents of directories (exception filedir). With DB one has to do queries to remove rows.
Plus DB tweaks for fixing one thing may not be best overall.