I've spent some time studying docs and source code and can't understand how to invalidate cache properly.
First of all, there are suspend and resume methods in SecurityCacheRulesInvalidator interface. As I understand, my component should call suspend method, invalidate cache and then call resume method, right? The question is how I should pass cache component to my component (which implements SecurityCacheRulesInvalidator)? What exactly I should inject? I also can't understand the following. When my main app changes permissions they are stored to a separate database. How can I make xwiki aware about these changes? What is the best way to communicate between 2 applications for this task? O Maybe there is a way to disable caching for some patterns: don't cache urls where space name is not on a list of predefined strings. If space name is on the list (it could be xwiki own spaces, like themes, etc), then we use cache, overwise we call settle every time (for my own spaces). Is it possible? -- View this message in context: http://xwiki.475771.n2.nabble.com/What-is-the-right-way-to-implement-XWiki-custom-permission-check-in-java-code-tp7598878p7599089.html Sent from the XWiki- Dev mailing list archive at Nabble.com. _______________________________________________ devs mailing list [email protected] http://lists.xwiki.org/mailman/listinfo/devs

