You are viewing a plain text version of this content. The canonical link for it is here.
Posted to issues@flink.apache.org by "Till Rohrmann (JIRA)" <ji...@apache.org> on 2019/02/26 16:04:00 UTC
[jira] [Closed] (FLINK-2518) Avoid predetermination of ports for
network services
[ https://issues.apache.org/jira/browse/FLINK-2518?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]
Till Rohrmann closed FLINK-2518.
--------------------------------
Resolution: Done
Only some test are using this utility.
> Avoid predetermination of ports for network services
> ----------------------------------------------------
>
> Key: FLINK-2518
> URL: https://issues.apache.org/jira/browse/FLINK-2518
> Project: Flink
> Issue Type: Improvement
> Components: Distributed Coordination
> Reporter: Till Rohrmann
> Priority: Major
>
> Some of Flink's network services use the {{NetUtils.getAvailablePort()}} to predetermine an available port for a service which is later started. This can lead to a race condition where two services have predetermined the same available port and later fail to instantiate because for one of them the port is already in use.
> This is, for example, the case for the {{NettyConnectionManager}} which is started after the {{TaskManager}} has registered at the {{JobManager}}. It would be better if we first start the network services with a random port, e.g. the {{NettyConnectionManager}}, and then send the bound port to the client. This will avoid problems like that.
--
This message was sent by Atlassian JIRA
(v7.6.3#76005)