You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@samza.apache.org by "Shanthoosh Venkataraman (JIRA)" <ji...@apache.org> on 2017/05/30 23:17:04 UTC

[jira] [Created] (SAMZA-1316) Request for tryBecomeLeader(time, TimeUnit) api in LeaderElector

Shanthoosh Venkataraman created SAMZA-1316:
----------------------------------------------

             Summary: Request for tryBecomeLeader(time, TimeUnit) api in LeaderElector 
                 Key: SAMZA-1316
                 URL: https://issues.apache.org/jira/browse/SAMZA-1316
             Project: Samza
          Issue Type: Improvement
            Reporter: Shanthoosh Venkataraman
            Priority: Minor


tryBecomeLeader() api in LeaderElector should take in retry mechanism ( (time, TimeUnit) or noOfRetriesOnFailure as parameter) and should not try repeatedly(recursively) and fail on irrecoverable exceptions after fixed retries. Clients should've tunable configuration to control retries.  

One more caveat is retries are programmed to happen after fixed amount of time(1000 ms). 
Should use ExponentialBackOff like in SystemConsumer.fetchMetadata().

When there're execution environmental problems(zookeeper death/network partitioning), a stream app can never become leader.  We should handle these extreme failure scenarios gracefully.





--
This message was sent by Atlassian JIRA
(v6.3.15#6346)