{"action":"created","issue":{"url":"https://api.github.com/repos/magento/magento2/issues/940","labels_url":"https://api.github.com/repos/magento/magento2/issues/940/labels{/name}","comments_url":"https://api.github.com/repos/magento/magento2/issues/940/comments","events_url":"https://api.github.com/repos/magento/magento2/issues/940/events","html_url":"https://github.com/magento/magento2/pull/940","id":53858556,"number":940,"title":"Added admin role id to backend menu cache key","user":{"login":"therouv","id":393419,"avatar_url":"https://avatars.githubusercontent.com/u/393419?v=3","gravatar_id":"","url":"https://api.github.com/users/therouv","html_url":"https://github.com/therouv","followers_url":"https://api.github.com/users/therouv/followers","following_url":"https://api.github.com/users/therouv/following{/other_user}","gists_url":"https://api.github.com/users/therouv/gists{/gist_id}","starred_url":"https://api.github.com/users/therouv/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/therouv/subscriptions","organizations_url":"https://api.github.com/users/therouv/orgs","repos_url":"https://api.github.com/users/therouv/repos","events_url":"https://api.github.com/users/therouv/events{/privacy}","received_events_url":"https://api.github.com/users/therouv/received_events","type":"User","site_admin":false},"labels":[{"url":"https://api.github.com/repos/magento/magento2/labels/bug","name":"bug","color":"eb6420"},{"url":"https://api.github.com/repos/magento/magento2/labels/PS","name":"PS","color":"fad8c7"}],"state":"open","locked":false,"assignee":null,"milestone":null,"comments":4,"created_at":"2015-01-09T11:26:28Z","updated_at":"2015-01-15T17:44:21Z","closed_at":null,"pull_request":{"url":"https://api.github.com/repos/magento/magento2/pulls/940","html_url":"https://github.com/magento/magento2/pull/940","diff_url":"https://github.com/magento/magento2/pull/940.diff","patch_url":"https://github.com/magento/magento2/pull/940.patch"},"body":"**Problem:**\r\nGiven that there are 2 admin permission roles for regular admin users which have different menu items allowed, the following problem occurs: \r\nIf an administrator now changes the admin role of an admin user, the admin user will see the old cached backend menu but if he clicks on a (now restricted) menu item, he will receive an \"Permission denied\" error - even after logging out and logging in again. This is very confusing for the admin user.\r\n\r\nUnder the current circumstances, the administrator has to clear the cache to make the changes in the backend menu visible and working properly. But clearing the cache can be risky on production environments and changes should be visible immediately.\r\n\r\n**Solution:**\r\nThis commit adds the current admin role id to the cache key for the backend menu block. The administrator can now change the admin role of an admin user. If the user then logs out and logs in again, the new menu is immediately visible which out the need to clearing the cache."},"comment":{"url":"https://api.github.com/repos/magento/magento2/issues/comments/70127960","html_url":"https://github.com/magento/magento2/pull/940#issuecomment-70127960","issue_url":"https://api.github.com/repos/magento/magento2/issues/940","id":70127960,"user":{"login":"kandy","id":100289,"avatar_url":"https://avatars.githubusercontent.com/u/100289?v=3","gravatar_id":"","url":"https://api.github.com/users/kandy","html_url":"https://github.com/kandy","followers_url":"https://api.github.com/users/kandy/followers","following_url":"https://api.github.com/users/kandy/following{/other_user}","gists_url":"https://api.github.com/users/kandy/gists{/gist_id}","starred_url":"https://api.github.com/users/kandy/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/kandy/subscriptions","organizations_url":"https://api.github.com/users/kandy/orgs","repos_url":"https://api.github.com/users/kandy/repos","events_url":"https://api.github.com/users/kandy/events{/privacy}","received_events_url":"https://api.github.com/users/kandy/received_events","type":"User","site_admin":false},"created_at":"2015-01-15T17:44:21Z","updated_at":"2015-01-15T17:44:21Z","body":"Maybe will be better to add user role as a tag in getCacheTags() and clear cache by the tag?"}}