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

Xintong Song commented on FLINK-21667:
--------------------------------------

Thanks [~trohrmann], I think that's a really good idea.

The lifecycle management and leadership management are coupled for the 
{{ResourceManager}}. It should simplify things a lot if we only start the 
{{ResourceManager}} when leadership is obtained, so that the 
{{ResourceManager}} and its components can always assume having the leadership.

I'll take a closer look into this.

BTW, I assume what you meant is {{Dispatcher}} and {{JobMaster}}? We don't have 
leader election for {{TaskExecutor}}.

> Standby RM might remove resources from Kubernetes
> -------------------------------------------------
>
>                 Key: FLINK-21667
>                 URL: https://issues.apache.org/jira/browse/FLINK-21667
>             Project: Flink
>          Issue Type: Bug
>          Components: Deployment / Kubernetes
>    Affects Versions: 1.12.2
>            Reporter: Xintong Song
>            Priority: Major
>             Fix For: 1.13.0, 1.12.3
>
>
> Currently, on initialization {{KubernetesResourceManagerDriver}} starts a 
> watch for receiving pod events. It could happen that it starts to receive 
> events before obtaining leadership. Consequently, a standby RM may remove 
> terminated pods from Kubernetes during handling the events.
> This is not very damaging atm, since the removed pods are already terminated 
> anyway. However, it would still be good for a standby RM to strictly 
> following the contract and make no modifications before obtaining leadership. 
> We might consider to postpone starting of the watch to when the leadership is 
> granted.



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

Reply via email to