Perhaps this already exists and I'm just not aware of it.
At some point DirectAdmin added a background_delete_size configuration option that sends account deletion to the background if they are over a certain size. I'm having trouble finding documentation on when this was added, but I believe the default value is 10GB.
I would propose that you add a flag to the CMD_API_SELECT_USERS function that can overwrite this. Something like neversendtobackground and when this POST variable is set to 1 then the background_delete_size option is ignored and account deletions are never sent to the background. They continue within the same process until they are complete.
This would probably overwrite background_delete_if_num_db_users as well.
And perhaps something similar to overwrite background_suspend_if_num_users for suspension. Although I suspect the default value of 0 for background_suspend_if_num_users means that this is disabled, but that's not immediately clear to me.
Reason being for this, I do all account deletions sequentially from the shell with an api-url call. Having some of those deletions happen within the same process (presumably those that are less than 10GB in size) and some deletions happening in the background, essentially skipping them from the list and going to the next sequential deletion can create a headache for me, because the local process I am running this from counts the account as deleted when it moves on to the next sequential delete, but if the account is over 10GB it hasn't really been deleted yet.
By having a flag that overwrites this, I can insure that all of my deletion happen sequentially no matter how large they are.
I could raise the background_delete_size variable, but ideally I'd prefer for resellers to still have this function as it doesn't appear to be causing any issues for them. It is only for my (admin) user deletes that it creates issues for me. A case-by-case ability to overwrite this would seem to be better.
I do realize that this probably isn't going to be a huge issue for most people. I depend on a slightly customized system for controlling account deletions. Being able to overwrite the background_delete_size setting would benefit me greatly.
At some point DirectAdmin added a background_delete_size configuration option that sends account deletion to the background if they are over a certain size. I'm having trouble finding documentation on when this was added, but I believe the default value is 10GB.
I would propose that you add a flag to the CMD_API_SELECT_USERS function that can overwrite this. Something like neversendtobackground and when this POST variable is set to 1 then the background_delete_size option is ignored and account deletions are never sent to the background. They continue within the same process until they are complete.
This would probably overwrite background_delete_if_num_db_users as well.
And perhaps something similar to overwrite background_suspend_if_num_users for suspension. Although I suspect the default value of 0 for background_suspend_if_num_users means that this is disabled, but that's not immediately clear to me.
Reason being for this, I do all account deletions sequentially from the shell with an api-url call. Having some of those deletions happen within the same process (presumably those that are less than 10GB in size) and some deletions happening in the background, essentially skipping them from the list and going to the next sequential deletion can create a headache for me, because the local process I am running this from counts the account as deleted when it moves on to the next sequential delete, but if the account is over 10GB it hasn't really been deleted yet.
By having a flag that overwrites this, I can insure that all of my deletion happen sequentially no matter how large they are.
I could raise the background_delete_size variable, but ideally I'd prefer for resellers to still have this function as it doesn't appear to be causing any issues for them. It is only for my (admin) user deletes that it creates issues for me. A case-by-case ability to overwrite this would seem to be better.
I do realize that this probably isn't going to be a huge issue for most people. I depend on a slightly customized system for controlling account deletions. Being able to overwrite the background_delete_size setting would benefit me greatly.