Cap LDAP user cache #25323

Merged
merged 1 commit into from Jul 4, 2016

Projects

None yet

5 participants

@butonic
Member
butonic commented Jul 1, 2016

Caps memory usage when iterating over all users, eg in a sync job

Before

6-ldap

After

7-ldapcapped

The memdump is from 9.0 without some of the memory pathes. Nevertheless, it should be recognizable that the createAndCache method has shrunk considerably.

@butonic butonic Cap LDAP user cache
b021d09
@mention-bot

By analyzing the blame information on this pull request, we identified @blizzz, @nickvergessen and @DeepDiver1975 to be potential reviewers

@butonic butonic added this to the 9.1-current milestone Jul 1, 2016
@PVince81
Collaborator
PVince81 commented Jul 1, 2016
@PVince81 PVince81 commented on the diff Jul 1, 2016
apps/user_ldap/lib/User/Manager.php
*/
- protected $users = array(
- 'byDN' => array(),
- 'byUid' => array(),
- );
+ protected $usersByDN;
@PVince81
PVince81 Jul 1, 2016 Collaborator

protected ? I hope no subclass uses these

@butonic
butonic Jul 1, 2016 Member

no subclasses use it.

@PVince81
Collaborator
PVince81 commented Jul 1, 2016

Did a quick test and LDAP still works 👍

@DeepDiver1975 DeepDiver1975 modified the milestone: 9.2, 9.1 Jul 1, 2016
@jvillafanez
Contributor

Makes sense 👍

@DeepDiver1975 DeepDiver1975 merged commit 6b4b337 into master Jul 4, 2016

20 of 22 checks passed

smashbox-on-docker-ci/DOCKER_IMAGE=ubuntu_oc_lamp-git,TEST_NAME=test_sharePermissions,mirallBranch=v2.0.2,slave=SMASH Build #15764 failed in 19 min
Details
smashbox-on-docker-ci/DOCKER_IMAGE=ubuntu_oc_lamp-git,TEST_NAME=test_basicSync@1,mirallBranch=v2.0.2,slave=SMASH Build #15764 in progress...
Details
Scrutinizer No new issues
Details
cla-bot-core Build #5088 succeeded in 26 sec
Details
continuous-integration/php-5.4 Build #5408 succeeded in 8 min 59 sec
Details
continuous-integration/travis-ci/pr The Travis CI build passed
Details
core-ci-linux-jsunit/database=sqlite,label=SLAVE Build #63280 succeeded in 3 min 48 sec
Details
core-ci-linux/database=mysql,label=SLAVE Build #32178 succeeded in 12 min
Details
core-ci-linux/database=oci,label=SLAVE Build #32178 succeeded in 48 min
Details
core-ci-linux/database=pgsql,label=SLAVE Build #32178 succeeded in 12 min
Details
core-ci-linux/database=sqlite,label=SLAVE Build #32178 succeeded in 5 min 48 sec
Details
ocs-api-integration-tests-ci Build #11962 succeeded in 10 min
Details
server-master-linux-externals-ci/database=sqlite,external=smb-silvershell,label=SLAVE Build #11450 succeeded in 1 min 25 sec
Details
server-master-linux-externals-ci/database=sqlite,external=swift-ceph,label=SLAVE Build #11450 succeeded in 5 min 0 sec
Details
server-master-linux-externals-ci/database=sqlite,external=webdav-ownCloud,label=SLAVE Build #11450 succeeded in 7 min 15 sec
Details
server-master-linux-externals-smb-windows-ext-ci/database=sqlite,external=smb-windows,label=master Build #23311 succeeded in 9 min 4 sec
Details
server-master-linux-php7-ci/database=sqlite,label=SLAVE Build #40506 succeeded in 6 min 6 sec
Details
smashbox-on-docker-ci/DOCKER_IMAGE=ubuntu_oc_lamp-git,TEST_NAME=litmus,mirallBranch=v2.0.2,slave=SMASH Build #15764 succeeded in 9 min 35 sec
Details
smashbox-on-docker-ci/DOCKER_IMAGE=ubuntu_oc_lamp-git,TEST_NAME=test_basicSync@0,mirallBranch=v2.0.2,slave=SMASH Build #15764 succeeded in 1 hr 22 min
Details
smashbox-on-docker-ci/DOCKER_IMAGE=ubuntu_oc_lamp-git,TEST_NAME=test_shareLink,mirallBranch=v2.0.2,slave=SMASH Build #15764 succeeded in 1 hr 32 min
Details
smashbox-on-docker-ci/DOCKER_IMAGE=ubuntu_oc_lamp-git,TEST_NAME=test_sharePropagationGroups,mirallBranch=v2.0.2,slave=SMASH Build #15764 succeeded in 1 hr 45 min
Details
smashbox-on-docker-ci/DOCKER_IMAGE=ubuntu_oc_lamp-git,TEST_NAME=test_sharePropagationInsideGroups,mirallBranch=v2.0.2,slave=SMASH Build #15764 succeeded in 1 hr 26 min
Details
@DeepDiver1975 DeepDiver1975 deleted the capldapusercache branch Jul 4, 2016
@PVince81
Collaborator
PVince81 commented Jul 6, 2016

@butonic also backport to stable9 ?

@DeepDiver1975
Member

stable9: #25324

@GitHubUser4234 GitHubUser4234 pushed a commit to GitHubUser4234/core that referenced this pull request Jul 22, 2016
@butonic @DeepDiver1975 butonic + DeepDiver1975 Cap LDAP user cache (#25323) d2d2a75
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment