[xwiki/xwiki-platform] bd4e05: XWIKI-24875: Trusted domains aren't updated after ...
Branch: refs/heads/stable-18.8.x Home: https://github.com/xwiki/xwiki-platform Commit: bd4e05d3f09bdc60ad7e7cea643e753bf2cd7edc https://github.com/xwiki/xwiki-platform/commit/bd4e05d3f09bdc60ad7e7cea643e7... Author: Michael Hamann <[email protected]> Date: 2026-09-15 (Tue, 15 Sep 2026) Changed paths: M xwiki-platform-core/xwiki-platform-url/xwiki-platform-url-default/pom.xml M xwiki-platform-core/xwiki-platform-url/xwiki-platform-url-default/src/main/java/org/xwiki/url/internal/DefaultURLSecurityManager.java M xwiki-platform-core/xwiki-platform-url/xwiki-platform-url-default/src/main/java/org/xwiki/url/internal/XWikiServerClassListener.java M xwiki-platform-core/xwiki-platform-url/xwiki-platform-url-default/src/test/java/org/xwiki/url/internal/DefaultURLSecurityManagerTest.java A xwiki-platform-core/xwiki-platform-url/xwiki-platform-url-default/src/test/java/org/xwiki/url/internal/XWikiServerClassListenerTest.java Log Message: ----------- XWIKI-24875: Trusted domains aren't updated after wiki descriptor change * fix the events XWikiServerClassListener listens to: the reference of an xobject event is the reference of the xobject, so the LocalDocumentReference of the xclass that was used never matched them and the cache of trusted domains was never invalidated. Use BaseObjectReference.anyEvents() instead, like AbstractDocumentConfigurationSource does. * keep the trusted domains in a memoizing supplier that is replaced on invalidation. This publishes the set safely, which the previous code didn't do as the field wasn't volatile, and it ensures that a computation that is running while the cache is invalidated cannot store the outdated descriptors it is based on. As the cache was never invalidated so far, these race conditions couldn't be surfaced before. * modernize the creation of the lists in DefaultURLSecurityManagerTest. Co-Authored-By: Claude Opus 5 (1M context) <[email protected]> (cherry picked from commit 61764fdd472baf6bb17f4cc6dd939d3eebff05e8) To unsubscribe from these emails, change your notification settings at https://github.com/xwiki/xwiki-platform/settings/notifications
participants (1)
-
XWiki Notifications