{"action":"created","issue":{"url":"https://api.github.com/repos/owncloud/core/issues/27312","repository_url":"https://api.github.com/repos/owncloud/core","labels_url":"https://api.github.com/repos/owncloud/core/issues/27312/labels{/name}","comments_url":"https://api.github.com/repos/owncloud/core/issues/27312/comments","events_url":"https://api.github.com/repos/owncloud/core/issues/27312/events","html_url":"https://github.com/owncloud/core/pull/27312","id":212066333,"number":27312,"title":"cache getStorageById","user":{"login":"butonic","id":956847,"avatar_url":"https://avatars3.githubusercontent.com/u/956847?v=3","gravatar_id":"","url":"https://api.github.com/users/butonic","html_url":"https://github.com/butonic","followers_url":"https://api.github.com/users/butonic/followers","following_url":"https://api.github.com/users/butonic/following{/other_user}","gists_url":"https://api.github.com/users/butonic/gists{/gist_id}","starred_url":"https://api.github.com/users/butonic/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/butonic/subscriptions","organizations_url":"https://api.github.com/users/butonic/orgs","repos_url":"https://api.github.com/users/butonic/repos","events_url":"https://api.github.com/users/butonic/events{/privacy}","received_events_url":"https://api.github.com/users/butonic/received_events","type":"User","site_admin":false},"labels":[{"id":132150275,"url":"https://api.github.com/repos/owncloud/core/labels/backport-request","name":"backport-request","color":"006b75","default":false},{"id":120033380,"url":"https://api.github.com/repos/owncloud/core/labels/blue-ticket","name":"blue-ticket","color":"0033CC","default":false},{"id":287820798,"url":"https://api.github.com/repos/owncloud/core/labels/comp:filesystem","name":"comp:filesystem","color":"d4c5f9","default":false},{"id":80995269,"url":"https://api.github.com/repos/owncloud/core/labels/performance","name":"performance","color":"fbca04","default":false}],"state":"open","locked":false,"assignee":null,"assignees":[],"milestone":{"url":"https://api.github.com/repos/owncloud/core/milestones/104","html_url":"https://github.com/owncloud/core/milestone/104","labels_url":"https://api.github.com/repos/owncloud/core/milestones/104/labels","id":2211524,"number":104,"title":"9.0.9","description":null,"creator":{"login":"PVince81","id":277525,"avatar_url":"https://avatars1.githubusercontent.com/u/277525?v=3","gravatar_id":"","url":"https://api.github.com/users/PVince81","html_url":"https://github.com/PVince81","followers_url":"https://api.github.com/users/PVince81/followers","following_url":"https://api.github.com/users/PVince81/following{/other_user}","gists_url":"https://api.github.com/users/PVince81/gists{/gist_id}","starred_url":"https://api.github.com/users/PVince81/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/PVince81/subscriptions","organizations_url":"https://api.github.com/users/PVince81/orgs","repos_url":"https://api.github.com/users/PVince81/repos","events_url":"https://api.github.com/users/PVince81/events{/privacy}","received_events_url":"https://api.github.com/users/PVince81/received_events","type":"User","site_admin":false},"open_issues":17,"closed_issues":9,"state":"open","created_at":"2016-12-22T07:31:25Z","updated_at":"2017-03-07T23:10:04Z","due_on":null,"closed_at":null},"comments":18,"created_at":"2017-03-06T09:29:37Z","updated_at":"2017-03-08T08:03:23Z","closed_at":null,"pull_request":{"url":"https://api.github.com/repos/owncloud/core/pulls/27312","html_url":"https://github.com/owncloud/core/pull/27312","diff_url":"https://github.com/owncloud/core/pull/27312.diff","patch_url":"https://github.com/owncloud/core/pull/27312.patch"},"body":"<!--\r\nThanks for submitting a change to ownCloud!\r\n\r\nThis is the bug tracker for the Server component. Find other components at https://github.com/owncloud/core/blob/master/.github/CONTRIBUTING.md#guidelines\r\n\r\nFor fixing potential security issues please see https://owncloud.org/security/\r\n\r\nTo make it possible for us to get your change reviewed and merged please fill out below information carefully.\r\n\r\nPlease note that any kind of change first has to be submitted to the master branch which holds the next major version of ownCloud.\r\n\r\nWe will carefully discuss if your change can or has to be backported to stable branches.\r\n-->\r\n\r\n## Description\r\ngetStorageById is indirectly called by the Availability wrapper, easily leading to hundreds of db queries. With this PR we not only cache the result for the current request but also push it to a distributed cache for 5 min, relieving the DB from executing that query.\r\n\r\n## How Has This Been Tested?\r\n<!--- Please describe in detail how you tested your changes. -->\r\n<!--- Include details of your testing environment, and the tests you ran to -->\r\n<!--- see how your change affects other areas of the code, etc. -->\r\nLocally with a user_shibboleth user and 100 incoming shares from 100 different user_shibboleth users (each user shared a single folder).\r\n\r\n## Types of changes\r\n<!--- What types of changes does your code introduce? Put an `x` in all the boxes that apply: -->\r\n- [ ] Bug fix (non-breaking change which fixes an issue)\r\n- [x] New feature (non-breaking change which adds functionality)\r\n- [ ] Breaking change (fix or feature that would cause existing functionality to change)\r\n\r\n## Checklist:\r\n<!--- Go over all the following points, and put an `x` in all the boxes that apply. -->\r\n<!--- If you're unsure about any of these, don't hesitate to ask. We're here to help! -->\r\n- [x] My code follows the code style of this project.\r\n- [ ] My change requires a change to the documentation.\r\n- [ ] I have updated the documentation accordingly.\r\n- [x] I have read the **CONTRIBUTING** document.\r\n- [ ] I have added tests to cover my changes.\r\n- [ ] All new and existing tests passed.\r\n\r\n"},"comment":{"url":"https://api.github.com/repos/owncloud/core/issues/comments/284973597","html_url":"https://github.com/owncloud/core/pull/27312#issuecomment-284973597","issue_url":"https://api.github.com/repos/owncloud/core/issues/27312","id":284973597,"user":{"login":"PVince81","id":277525,"avatar_url":"https://avatars1.githubusercontent.com/u/277525?v=3","gravatar_id":"","url":"https://api.github.com/users/PVince81","html_url":"https://github.com/PVince81","followers_url":"https://api.github.com/users/PVince81/followers","following_url":"https://api.github.com/users/PVince81/following{/other_user}","gists_url":"https://api.github.com/users/PVince81/gists{/gist_id}","starred_url":"https://api.github.com/users/PVince81/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/PVince81/subscriptions","organizations_url":"https://api.github.com/users/PVince81/orgs","repos_url":"https://api.github.com/users/PVince81/repos","events_url":"https://api.github.com/users/PVince81/events{/privacy}","received_events_url":"https://api.github.com/users/PVince81/received_events","type":"User","site_admin":false},"created_at":"2017-03-08T08:03:23Z","updated_at":"2017-03-08T08:03:23Z","body":"Code looks good. Let me try and find ways to break this..."}}
{"actor":{"display_login":"PVince81"}}