nextcloud / quota_warning

❗💾 This app sends notifications to users when they reached 85, 90 and 95% of their quota.
https://apps.nextcloud.com/apps/quota_warning
GNU Affero General Public License v3.0
17 stars 12 forks source link

Single job for all users instead of one job per user #203

Closed akhil1508 closed 2 weeks ago

akhil1508 commented 4 months ago
akhil1508 commented 4 months ago

@nickvergessen Does this make sense? Would be happy to contribute a PR if it sounds okay..

nickvergessen commented 4 months ago

Adjusting the repairstep will make updating faster, yeah. But a single job for all could be even more problematic as it would run forever. The problem is setting up the storage of the user to check the quota. This does not get faster if you do it for more users as you need to re-set up the filesystem for each user anyway.

nickvergessen commented 4 months ago

That being said, the repair step should only be needed initially. It is listed for install only: https://github.com/nextcloud/quota_warning/blob/main/appinfo/info.xml#L29-L31

If it retriggers on update, that might be a bug in itself. Not sure if all background jobs are deleted if they would run while the app is disabled, but if not we could save an app config that initial populating was done and then skip the repairstep in the future.