[
https://issues.apache.org/jira/browse/SLING-3392?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=13905359#comment-13905359
]
Carsten Ziegeler commented on SLING-3392:
-----------------------------------------
I question to workaround potential problems in the repository, especially as
search is used all over the place. And if it is not working here, chances are
high that its not working in other places. And avoiding search altogether seems
very unlikely.
However, in this case, we could replace the search with traversing and make
everything a little bit more robust wrt to repository problems.
I don't see how to create a good non flat hierarchy - we can't use any
randomness as the path needs to be the exact same on all instances in a cluster
to make locking work. So the only option would be to use the job name - however
in order to create a nice /non-flat distribution we would need to know how the
name is constructed, it might just differ in one single character at any place
in the string. And having a hierarchy makes the cleanup way harde, as we also
would need to remove empty folders which could cause conflicts in the cluster
etc.
> JobManager MaintenanceTask should not rely on search for removing locks
> -----------------------------------------------------------------------
>
> Key: SLING-3392
> URL: https://issues.apache.org/jira/browse/SLING-3392
> Project: Sling
> Issue Type: Bug
> Components: Extensions
> Affects Versions: Event 3.3.4
> Reporter: Amit Gupta
> Assignee: Carsten Ziegeler
> Fix For: Event 3.3.6
>
>
> org.apache.sling.event.impl.jobs.MaintenanceTask relies on search to find
> obsolete locks and remove those.
> Search can fail for reasons such as index corruption. It should not rely on
> search for such critical tasks.
> And, another issue with locks is that those are created in a flat hierarchy.
--
This message was sent by Atlassian JIRA
(v6.1.5#6160)