Max Number of users


Not sure if this is a bug or what

Im on 1.8.2 and i have about 13000 users

Now going to users or roles from the dsp web interface fails with:
/rest/system/role/?app_name=admin&fields=*&related=users,apps,role_service_accesses,role_system_accesses,lookup_keys 500 (Internal Server Error)

and from swager:
/rest/system/user?limit=1 works fine
/rest/system/user?limit=1000 works fine
/rest/system/user?limit=10000 returns 500 no content

same with roles

cant seem to find anything in the logs


13,000 users is far too many to return at once. You are hitting a PHP memory limit, which is causing the 500 error.

Currently, the pagination and return limits that work for normal records calls is not being applied to /system/role/ and /system/user/. This is a bug that @leehicks has already fixed, and the fix will be included in the next release.

Other records calls are currently paginated according to the dsp.db_max_records_returned parameter in the PHP config. For instance, with an API call with parameter ?limit=10000 the system will return the first 1000 records as “Page 1” to prevent high memory usage. This parameter is found in config/common.config.php:

/** The default number of records to return at once for database queries */
'dsp.db_max_records_returned'   => 1000,

Right now /system/role/ and /system/user/ are not honoring this setting, but this will be resolved in the next release. For your convenience, I have created GitHub Issue #56 for this bug. You may subscribe to the GitHub Issue so you’re notified when it’s included in a release.



I’ll have a look at the dev branch for changes coz i need a work around right now as this is a production server.