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

Konrad Windszus edited comment on SLING-12245 at 2/8/24 10:18 AM:
------------------------------------------------------------------

The receiver does not know if it is ADDED event due to a move operation or a 
regular ADDED event. Only in the former case a traversal is necessary. If you 
do it for every ADDED event outside the path there is a high chance that you 
treat the same configuration twice (e.g. when adding a configuration via 
content package) which will first trigger an ADDED event on the ancestor as 
well followed by the ADDED event on the actual configuration resource. It gets 
worse the more levels the ADDED event is away from the actually relevant 
resources (traversing each time adds a considerable load in the system and 
deduplication will be impossible)


was (Author: kwin):
The receiver does not know if it is ADDED event due to a move operation or a 
regular ADDED event. Only in the former case a traversal is necessary. If you 
do it for every ADDED event outside the path there is a high chance that you 
treat the same configuration twice (e.g. when adding a configuration via 
content package) which will first trigger an ADDED event on the ancestor as 
well followed by the ADDED event on the actual configuration resource.

> Sling Rewriter does not detect configuration changes coming in via move
> -----------------------------------------------------------------------
>
>                 Key: SLING-12245
>                 URL: https://issues.apache.org/jira/browse/SLING-12245
>             Project: Sling
>          Issue Type: Improvement
>    Affects Versions: Rewriter 1.3.10
>            Reporter: Konrad Windszus
>            Priority: Major
>
> If one renames/moves a JCR node from {{/apps/my/config/invalid-rewriter}} to 
> {{/apps/my/config/rewriter}} the new rewriter configuration is not being 
> detected by the {{ProcessorManagerImpl}} due to the 
> {{ResourceChangeListener}} only being configured to listen for changes below 
> the {{rewriter}} resource 
> (https://github.com/apache/sling-org-apache-sling-rewriter/blob/4d1952648e35e7001236f282040a78479f7726d4/src/main/java/org/apache/sling/rewriter/impl/ProcessorManagerImpl.java#L69).



--
This message was sent by Atlassian Jira
(v8.20.10#820010)

Reply via email to