forked from DevotedMC/NameLayer
-
Notifications
You must be signed in to change notification settings - Fork 19
Open
Description
Deleting rows out of indexed tables causes rows to be reordered, which is really slow for production servers (Civclassic has 4.2 million entries in the permissionByGroup table).
Thus editing perms is laggy, even if the db query is done async it sometimes times out. Every second change is a deletion from permissionByGroup.
A faster way would be to store a boolean flag for every perm, for every rank for every group, update that as needed and bulk delete only if groups are deleted. This would bloat the table size, but to an acceptable degree in comparison to the current performance issues