sling-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Dirk Rudolph (Jira)" <j...@apache.org>
Subject [jira] [Commented] (SLING-8946) Non-deterministic shadowing of resource observation
Date Mon, 10 Feb 2020 07:51:00 GMT

    [ https://issues.apache.org/jira/browse/SLING-8946?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=17033416#comment-17033416
] 

Dirk Rudolph commented on SLING-8946:
-------------------------------------

[~sonagupt] please keep in mind that I am not an Adobe employee and can only barely reconstruct
the dependency tree of the tests you share with what is available publicly. Also please make
sure that you are actually allowed to share those packages of code here.

In this particular case (test2.zip) I cannot get the tests running. Which version/patch level
of AEM are they executed against? 

I don't see how the failure I get relate to the change here.

> Non-deterministic shadowing of resource observation
> ---------------------------------------------------
>
>                 Key: SLING-8946
>                 URL: https://issues.apache.org/jira/browse/SLING-8946
>             Project: Sling
>          Issue Type: Bug
>          Components: ResourceResolver
>    Affects Versions: Resource Resolver 1.5.34
>            Reporter: Dirk Rudolph
>            Assignee: Robert Munteanu
>            Priority: Critical
>             Fix For: Resource Resolver 1.6.18
>
>         Attachments: test2.zip
>
>          Time Spent: 1.5h
>  Remaining Estimate: 0h
>
> The BasicObservationReporter implements shadowing of events being propagated per ResourceProvider
instance [1]. Assuming we do have 2 ResourceProviders registered, where the one shadows the
other like this:
>  - RP A registered on /
>  - RP B registered on /path
> then currently the excludes given to the BasicObservationReporter are different depending
on either RP A or RP B gets registered first:
>  - RP A before RP B => excludes are empty
>  - RP B before RP A => excludes contain /path
> This is because only the newly registered RP gets its ProviderContext updated [2]
> Same applies if RP B is registered before RP A and gets unregistered. In that case the
ObservationReporter of RP A stays untouched.
> [1] [https://github.com/apache/sling-org-apache-sling-resourceresolver/blob/master/src/main/java/org/apache/sling/resourceresolver/impl/observation/BasicObservationReporter.java#L102]
>  [2] [https://github.com/apache/sling-org-apache-sling-resourceresolver/blob/master/src/main/java/org/apache/sling/resourceresolver/impl/providers/ResourceProviderTracker.java#L358]



--
This message was sent by Atlassian Jira
(v8.3.4#803005)

Mime
View raw message