Skip to content

[WIP] read all relevant user attributes on login, in one query. saves us some. - #12943

Closed
blizzz wants to merge 1 commit into
masterfrom
ldap-batch-read-attrs
Closed

[WIP] read all relevant user attributes on login, in one query. saves us some.#12943
blizzz wants to merge 1 commit into
masterfrom
ldap-batch-read-attrs

Conversation

@blizzz

@blizzz blizzz commented Dec 18, 2014

Copy link
Copy Markdown
Contributor

What has happened before:

  1. upon login, we queried LDAP for the DN corresponding to the username
  2. we would do a bind to verify authentication
  3. if they need to be updated, single readQueries will be done for quota, email, avatar
  4. home directory attribute would also be read with a single request

What we do now:

  1. upon login, we query LDAP for DN, quota, email, avatar, home directory attribute in the same request
  2. we do a bing to verfiy authentication
  3. we apply (i.e. store or cache) all the values we fetched before without any single additional request

I.e. in general this brings us performance improvements by less queries to the LDAP server. LDAP server will be happy, too, about less work. Helped with https://github.com/owncloud/enterprise/issues/442 in a OC 7 version (although it was not the root problem).

Also solves #12823

todos left

  • user tests need to be adjusted and extended

@blizzz blizzz self-assigned this Dec 18, 2014
@blizzz blizzz added this to the 8.0-current milestone Dec 18, 2014
@scrutinizer-notifier

Copy link
Copy Markdown

The inspection completed: 11 new issues, 7 updated code elements

@karlitschek

Copy link
Copy Markdown
Contributor

@craigpg

@DeepDiver1975

Copy link
Copy Markdown
Member

needs rebase and in WIP state -> OC8.1

@DeepDiver1975 DeepDiver1975 modified the milestones: 8.1-next, 8.0-current Dec 22, 2014
@DeepDiver1975 DeepDiver1975 modified the milestones: 8.2-next, 8.1-current Apr 2, 2015
@ghost

ghost commented Apr 30, 2015

Copy link
Copy Markdown

Refer to this link for build results (access rights to CI server needed):
https://ci.owncloud.org//job/pull-request-analyser-ng-simple/12058/

Build result: FAILURE

[...truncated 159 lines...] > git config --local --remove-section credential # timeout=10 > git config remote.origin.url https://github.com/owncloud/core.git # timeout=10 > git config --add remote.origin.fetch +refs/heads/:refs/remotes/origin/ # timeout=10 > git config remote.origin.url https://github.com/owncloud/core.git # timeout=10Fetching upstream changes from https://github.com/owncloud/core.gitusing GIT_SSH to set credentials using .gitcredentials to set credentials > git config --local credential.helper store --file=/tmp/git4683420848359394944.credentials # timeout=10 > git -c core.askpass=true fetch --tags --progress https://github.com/owncloud/core.git +refs/pull/:refs/remotes/origin/pr/ > git config --local --remove-section credential # timeout=10 > git rev-parse a6e7f67^{commit} # timeout=10Checking out Revision a6e7f67 (detached) > git config core.sparsecheckout # timeout=10 > git checkout -f a6e7f67 > git rev-list 2b041b1 # timeout=10 > git remote # timeout=10 > git submodule init # timeout=10 > git submodule sync # timeout=10 > git config --get remote.origin.url # timeout=10 > git submodule update --init --recursiveTriggering pull-request-analyser-ng-simple » SLAVEConfiguration pull-request-analyser-ng-simple » SLAVE is still in the queue: Waiting for next available executor on SLAVEpull-request-analyser-ng-simple » SLAVE completed with result FAILURESetting status of a6e7f67 to FAILURE with url https://ci.owncloud.org/job/pull-request-analyser-ng-simple/12058/ and message: Build finished.
💣 Test FAILed. 💣

nooo432

@PVince81

PVince81 commented Jul 3, 2015

Copy link
Copy Markdown
Contributor

@blizzz is this oldie still valid ?

@blizzz

blizzz commented Jul 10, 2015

Copy link
Copy Markdown
Contributor Author

With extending it also to user searches it would fix #17362

@blizzz

blizzz commented Aug 20, 2015

Copy link
Copy Markdown
Contributor Author

replaced by #18469 (too many changes in master since)

@blizzz blizzz closed this Aug 20, 2015
@blizzz
blizzz deleted the ldap-batch-read-attrs branch August 20, 2015 23:03
@lock lock Bot locked as resolved and limited conversation to collaborators Aug 10, 2019
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

6 participants