Topic: API throttling/delete user throttling? Mass user delete code hangs.
==== REQUIRED BASIC INFO OF YOUR IREDMAIL SERVER ====
- iRedMail version (check /etc/iredmail-release): 0.99
- Deployed with iRedMail Easy or the downloadable installer? downloadable
- Linux/BSD distribution name and version: Centos
- Store mail accounts in which backend (LDAP/MySQL/PGSQL): LDAP
- Web server (Apache or Nginx): Nginx
- Manage mail accounts with iRedAdmin-Pro? Yes (3.5)
- [IMPORTANT] Related original log or error message is required if you're experiencing an issue.
Is any throttling applied to API calls or user deletion? I've written code which deletes users which haven't logged in for more than 365 days. I've configured last login tracking as described in https://docs.iredmail.org/track.user.last.login.html
My code authenticates to the API by posting to /iredadmin/login. All is well and I receive the session cookie. Next, I loop through the MariaDB last_login table for users who haven't logged in for more than 365 days.
Within the loop I access /iredadmin/api/user/(username) using delete and remove the associated record from the MariaDB table. All is well. On the second iteration my code hangs when I access /iredadmin/api/user/(username). No error, not even a timeout.
If API throttling is in place, can it be disabled?