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

ASF GitHub Bot commented on FLINK-8942:
---------------------------------------

Github user tillrohrmann commented on a diff in the pull request:

    https://github.com/apache/flink/pull/5699#discussion_r175726725
  
    --- Diff: 
flink-runtime/src/main/java/org/apache/flink/runtime/heartbeat/HeartbeatManagerImpl.java
 ---
    @@ -106,8 +107,8 @@ Executor getExecutor() {
                return heartbeatListener;
        }
     
    -   Collection<HeartbeatManagerImpl.HeartbeatMonitor<O>> 
getHeartbeatTargets() {
    -           return heartbeatTargets.values();
    +   Collection<Map.Entry<ResourceID, HeartbeatMonitor<O>>> 
getHeartbeatTargets() {
    --- End diff --
    
    What about adding a `getTargetID()` to the `HeartbeatMonitor`? Then we 
would not have to expose, even though it is an internal method, that we use a 
`Map` to store the heartbeat targets. We could then keep the return type 
`Collection<HeartbeatMonitor>`.


> Pass target ResourceID to HeartbeatListener#retrievePayload
> -----------------------------------------------------------
>
>                 Key: FLINK-8942
>                 URL: https://issues.apache.org/jira/browse/FLINK-8942
>             Project: Flink
>          Issue Type: Improvement
>          Components: Distributed Coordination
>    Affects Versions: 1.5.0
>            Reporter: Chesnay Schepler
>            Assignee: Chesnay Schepler
>            Priority: Blocker
>             Fix For: 1.5.0
>
>
> For FLINK-8881 we need a way to determine to which JobManager we are sending 
> the heartbeats, otherwise we would have to send all accumulators, that is for 
> all jobs, to each connected JobManager.
> I suggest to pass the targetĀ {{ResourceID}} to 
> {{HeartbeatListener#retrievePayload}} which generates the payload.



--
This message was sent by Atlassian JIRA
(v7.6.3#76005)

Reply via email to