log: Adds details to an exception's message.
This commit is contained in:
parent
f2cd3891e1
commit
200b383752
@ -327,6 +327,8 @@ public class HostCandidateHarvester
|
|||||||
}
|
}
|
||||||
|
|
||||||
boolean boundAtLeastOneSocket = false;
|
boolean boundAtLeastOneSocket = false;
|
||||||
|
boolean foundAtLeastOneUsableInterface = false;
|
||||||
|
boolean foundAtLeastOneUsableAddress = false;
|
||||||
while (interfaces.hasMoreElements())
|
while (interfaces.hasMoreElements())
|
||||||
{
|
{
|
||||||
NetworkInterface iface = interfaces.nextElement();
|
NetworkInterface iface = interfaces.nextElement();
|
||||||
@ -338,6 +340,7 @@ public class HostCandidateHarvester
|
|||||||
//this one is obviously not going to do
|
//this one is obviously not going to do
|
||||||
continue;
|
continue;
|
||||||
}
|
}
|
||||||
|
foundAtLeastOneUsableInterface = true;
|
||||||
|
|
||||||
Enumeration<InetAddress> addresses = iface.getInetAddresses();
|
Enumeration<InetAddress> addresses = iface.getInetAddresses();
|
||||||
|
|
||||||
@ -356,6 +359,7 @@ public class HostCandidateHarvester
|
|||||||
{
|
{
|
||||||
continue;
|
continue;
|
||||||
}
|
}
|
||||||
|
foundAtLeastOneUsableAddress = true;
|
||||||
|
|
||||||
if((addr instanceof Inet4Address) || !isIPv6Disabled)
|
if((addr instanceof Inet4Address) || !isIPv6Disabled)
|
||||||
{
|
{
|
||||||
@ -423,14 +427,18 @@ public class HostCandidateHarvester
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
if(!boundAtLeastOneSocket)
|
if (!boundAtLeastOneSocket)
|
||||||
{
|
{
|
||||||
throw new IOException(
|
throw new IOException(
|
||||||
"Failed to bind even a single host candidate for component:"
|
"Failed to bind even a single host candidate for component:"
|
||||||
+ component
|
+ component
|
||||||
+ " preferredPort=" + preferredPort
|
+ " preferredPort=" + preferredPort
|
||||||
+ " minPort=" + minPort
|
+ " minPort=" + minPort
|
||||||
+ " maxPort=" + maxPort);
|
+ " maxPort=" + maxPort
|
||||||
|
+ " foundAtLeastOneUsableInterface="
|
||||||
|
+ foundAtLeastOneUsableInterface
|
||||||
|
+ " foundAtLeastOneUsableAddress="
|
||||||
|
+ foundAtLeastOneUsableAddress);
|
||||||
}
|
}
|
||||||
|
|
||||||
this.harvestStatistics
|
this.harvestStatistics
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user