GitHub user tillrohrmann opened a pull request:
https://github.com/apache/flink/pull/1758
[FLINK-3570] [runtime] Use InetAddress.getLocalHost() as heuristic to find
local address
The ConnectionUtils.findAddressUsingStrategy method tries to find out the
local address which is
accessible by other machines of the cluster. It tries to connect to a
specified address to do so.
In case that the no connection could be established, it uses an heuristic.
Before it randomly
picked a NetworkInterface which is bound to an Inet4Address, not a loop
back address and not a
link local address. In most cases it makes more sense to default to the
InetAddress.getLocalHost() address instead. This PR replaces the old
heuristic with simply
returning the InetAddress.getLocalHost(). This of course requires that the
system on which Flink
is running, is properly configured.
You can merge this pull request into a Git repository by running:
$ git pull https://github.com/tillrohrmann/flink fixNICHeuristic
Alternatively you can review and apply these changes as the patch at:
https://github.com/apache/flink/pull/1758.patch
To close this pull request, make a commit to your master/trunk branch
with (at least) the following in the commit message:
This closes #1758
----
commit 121fe848d2ef55af36445dae7e8b0a9ffb468daf
Author: Till Rohrmann <[email protected]>
Date: 2016-03-03T13:24:42Z
[FLINK-3570] [runtime] Use InetAddress.getLocalHost() as heuristic to find
local address
The ConnectionUtils.findAddressUsingStrategy method tries to find out the
local address which is
accessible by other machines of the cluster. It tries to connect to a
specified address to do so.
In case that the no connection could be established, it uses an heuristic.
Before it randomly
picked a NetworkInterface which is bound to an Inet4Address, not a loop
back address and not a
link local address. In most cases it makes more sense to default to the
InetAddress.getLocalHost() address instead. This PR replaces the old
heuristic with simply
returning the InetAddress.getLocalHost(). This of course requires that the
system on which Flink
is running, is properly configured.
----
---
If your project is set up for it, you can reply to this email and have your
reply appear on GitHub as well. If your project does not have this feature
enabled and wishes so, or if the feature is enabled but not working, please
contact infrastructure at [email protected] or file a JIRA ticket
with INFRA.
---