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

Timothee Maret commented on SLING-5435:
---------------------------------------

I don't think there is such process in Sling. Indeed, the Sling components 
handling topology events are located in the {{org.apache.sling.event.impl}} 
package and AFAIU those components deal with data stored in the repository and 
attempt to process data with a guaranteed single execution. For those use 
cases, the repository sync is likely helping toward that goal.

However, topology handlers in application code, for instance in Adobe AEM or 
services based on Adobe AEM, may not need that repository sync. 
I can't share pointers here because it is proprietary code, but I can give you 
some potential use cases such as data importers (from an external source to the 
repository), data validation tasks and notification services (e.g. sends email) 
which typically only one leader instance executes.

> Decouple processes that depend on cluster leader elections from the cluster 
> leader elections.
> ---------------------------------------------------------------------------------------------
>
>                 Key: SLING-5435
>                 URL: https://issues.apache.org/jira/browse/SLING-5435
>             Project: Sling
>          Issue Type: Improvement
>          Components: General
>            Reporter: Ian Boston
>
> Currently there are many processes in Sling that must complete before a Sling 
> Discovery cluster leader election is declared complete. These processes 
> include things like transferring all Jobs from the old leader to the new 
> leader and waiting for the data to appear visible on the new leader. This 
> introduces an additional overhead to the leader election process which 
> introduces a higher than desirable timeout for elections and heartbeat. This 
> higher than desirable timeout precludes the use of more efficient election 
> and distributed consensus algorithms as implemented in Etcd, Zookeeper or 
> implementations of RAFT.
> If the election could be declared complete leaving individual components to 
> manage their own post election operations (ie decoupling those processes from 
> the election), then faster election or alternative Discovery implementations 
> such as the one implemented on etcd could be used.



--
This message was sent by Atlassian JIRA
(v6.3.4#6332)

Reply via email to