[ https://issues.apache.org/jira/browse/OAK-5296?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=15745279#comment-15745279
]
Michael Dürig commented on OAK-5296:
------------------------------------
[~anchela], I need your help here to verify my line of thinking and extract a test case reproducing
the wrong refresh behaviour.
> MutableRoot.refresh does not correctly refresh tree permissions
> ---------------------------------------------------------------
>
> Key: OAK-5296
> URL: https://issues.apache.org/jira/browse/OAK-5296
> Project: Jackrabbit Oak
> Issue Type: Bug
> Components: core
> Reporter: Michael Dürig
> Assignee: Michael Dürig
> Priority: Blocker
> Fix For: 1.6
>
>
> Consider the following excerpt of a stack trace:
> {noformat}
> at org.apache.jackrabbit.oak.security.authorization.permission.PermissionProviderImpl.getCompiledPermissions(PermissionProviderImpl.java:162)
> at org.apache.jackrabbit.oak.security.authorization.permission.PermissionProviderImpl.getTreePermission(PermissionProviderImpl.java:104)
> at org.apache.jackrabbit.oak.core.SecureNodeBuilder.getTreePermission(SecureNodeBuilder.java:356)
> at org.apache.jackrabbit.oak.core.SecureNodeBuilder.baseChanged(SecureNodeBuilder.java:166)
> at org.apache.jackrabbit.oak.core.MutableRoot.refresh(MutableRoot.java:236)
> {noformat}
> {{MutableRoot.refresh()}} [ends up calling | https://github.com/apache/jackrabbit-oak/blob/trunk/oak-core/src/main/java/org/apache/jackrabbit/oak/core/MutableRoot.java#L236]
{{PermissionProviderImpl.getCompiledPermissions}}, which in turn uses the current (not yet
fully refreshed) root for compiling the permissions. The permissions provider (and its root)
are [refreshed|https://github.com/apache/jackrabbit-oak/blob/trunk/oak-core/src/main/java/org/apache/jackrabbit/oak/core/MutableRoot.java#L239]
only afterwards.
--
This message was sent by Atlassian JIRA
(v6.3.4#6332)
|