remove duplicate logging of port conflicts (#1160)

Signed-off-by: Sally MacFarlane <sally.macfarlane@consensys.net>
pull/1183/head
Sally MacFarlane 4 years ago committed by GitHub
parent 17556485f3
commit 50736b2bd9
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
  1. 4
      ethereum/p2p/src/main/java/org/hyperledger/besu/ethereum/p2p/rlpx/RlpxAgent.java
  2. 2
      ethereum/p2p/src/main/java/org/hyperledger/besu/ethereum/p2p/rlpx/connections/netty/NettyConnectionInitializer.java

@ -133,7 +133,9 @@ public class RlpxAgent {
.whenComplete(
(res, err) -> {
if (err != null) {
LOG.error("Failed to start P2P RLPx agent.", err);
// the detail of this error is already logged by the completeExceptionally() call in
// NettyConnectionInitializer
LOG.error("Failed to start P2P RLPx agent. Check for port conflicts.");
}
});
}

@ -112,7 +112,7 @@ public class NettyConnectionInitializer implements ConnectionInitializer {
if (!future.isSuccess() || socketAddress == null) {
final String message =
String.format(
"Unable start listening on %s:%s. Check for port conflicts.",
"Unable to start listening on %s:%s. Check for port conflicts.",
config.getBindHost(), config.getBindPort());
listeningPortFuture.completeExceptionally(
new IllegalStateException(message, future.cause()));

Loading…
Cancel
Save