[MAGNOLIA-5534] Anonymous user permissions are not cached Created: 10/Dec/13  Updated: 08/Jan/14  Resolved: 12/Dec/13

Status: Closed
Project: Magnolia
Component/s: core, security
Affects Version/s: 4.5
Fix Version/s: 4.5.15, 5.2.1

Type: Bug Priority: Blocker
Reporter: Jan Haderka Assignee: Milan Divilek
Resolution: Fixed Votes: 0
Labels: maintenance
Remaining Estimate: Not Specified
Time Spent: Not Specified
Original Estimate: Not Specified

Issue Links:
causality
caused by MAGNOLIA-5455 Replace use of queries with node trav... Closed
Template:
Acceptance criteria:
Empty
Task DoD:
[ ]* Doc/release notes changes? Comment present?
[ ]* Downstream builds green?
[ ]* Solution information and context easily available?
[ ]* Tests
[ ]* FixVersion filled and not yet released
[ ]  Architecture Decision Record (ADR)
Bug DoR:
[ ]* Steps to reproduce, expected, and actual results filled
[ ]* Affected version filled
Release notes required:
Yes
Date of First Response:

 Description   

Since overhaul of security the anonymous user permissions are no longer cached. While having near zero impact under normal load, under high load on public this can lead to a noticeable performance loss. This issue was made more prominent by changes made for MAGNOLIA-5455.



 Comments   
Comment by Jan Haderka [ 10/Dec/13 ]

not really caused-by, more like exposed-by if there was such a link

Comment by Jan Haderka [ 10/Dec/13 ]

info.magnolia.cms.security.Security or info.magnolia.cms.security.SecuritySupport would be pbly best place for caching. When re-introducing caching (was present until 4.5) make sure cached info is flushed on modifications to users, usergroups, userroles workspaces via observation (same is most likely still done for cached anonymous user object (or should be anyway).

Comment by Jan Haderka [ 10/Dec/13 ]
  • rewrite brittle code & add warning
  • fix comments on props
  • revert collection in PrincipalCollectionImpl to final
Comment by Milan Divilek [ 11/Dec/13 ]

Reopen:
2013-12-11 10:13:45,981 WARN  info.magnolia.module.cache.filter.CacheFilter     : The following URL was blocked for longer than 10 seconds and has timed-out. The request has been blocked as another request is already processing the same resource. [url=http://localhost:8080/magnoliaPublic/demo-features/special-templates/event-overview.html]
2013-12-11 10:13:58,603 WARN  info.magnolia.module.cache.filter.CacheFilter     : The following URL took longer than 10 seconds (29134 ms) to render. This might cause timeout exceptions on other requests to the same URI. [url=http://localhost:8080/magnoliaPublic/demo-features/special-templates/event-overview.html], [key=DefaultCacheKey{uri='/demo-features/special-templates/event-overview.html', serverName='localhost', locale='en', channel='desktop', params={}', secure='false', method='get'}]

Generated at Mon Feb 12 04:06:03 CET 2024 using Jira 9.4.2#940002-sha1:46d1a51de284217efdcb32434eab47a99af2938b.