Signed-off-by: Sally MacFarlane <sally.macfarlane@consensys.net>
pull/3063/head
Sally MacFarlane 3 years ago committed by GitHub
parent c0b1316d7b
commit b682f8c28b
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
  1. 2
      besu/src/main/java/org/hyperledger/besu/cli/options/unstable/NetworkingOptions.java
  2. 2
      besu/src/test/java/org/hyperledger/besu/cli/options/NetworkingOptionsTest.java
  3. 4
      ethereum/p2p/src/main/java/org/hyperledger/besu/ethereum/p2p/config/NetworkingConfiguration.java

@ -47,7 +47,7 @@ public class NetworkingOptions implements CLIOptions<NetworkingConfiguration> {
description = description =
"The frequency (in seconds) at which to check maintained connections (default: ${DEFAULT-VALUE})") "The frequency (in seconds) at which to check maintained connections (default: ${DEFAULT-VALUE})")
private int checkMaintainedConnectionsFrequencySec = private int checkMaintainedConnectionsFrequencySec =
NetworkingConfiguration.DEFAULT_CHECK_MAINTAINED_CONNECTSION_FREQUENCY_SEC; NetworkingConfiguration.DEFAULT_CHECK_MAINTAINED_CONNECTIONS_FREQUENCY_SEC;
private NetworkingOptions() {} private NetworkingOptions() {}

@ -83,7 +83,7 @@ public class NetworkingOptionsTest
config.setInitiateConnectionsFrequency( config.setInitiateConnectionsFrequency(
NetworkingConfiguration.DEFAULT_INITIATE_CONNECTIONS_FREQUENCY_SEC + 10); NetworkingConfiguration.DEFAULT_INITIATE_CONNECTIONS_FREQUENCY_SEC + 10);
config.setCheckMaintainedConnectionsFrequency( config.setCheckMaintainedConnectionsFrequency(
NetworkingConfiguration.DEFAULT_CHECK_MAINTAINED_CONNECTSION_FREQUENCY_SEC + 10); NetworkingConfiguration.DEFAULT_CHECK_MAINTAINED_CONNECTIONS_FREQUENCY_SEC + 10);
return config; return config;
} }

@ -20,13 +20,13 @@ import java.util.Objects;
public class NetworkingConfiguration { public class NetworkingConfiguration {
public static final int DEFAULT_INITIATE_CONNECTIONS_FREQUENCY_SEC = 30; public static final int DEFAULT_INITIATE_CONNECTIONS_FREQUENCY_SEC = 30;
public static final int DEFAULT_CHECK_MAINTAINED_CONNECTSION_FREQUENCY_SEC = 60; public static final int DEFAULT_CHECK_MAINTAINED_CONNECTIONS_FREQUENCY_SEC = 60;
private DiscoveryConfiguration discovery = new DiscoveryConfiguration(); private DiscoveryConfiguration discovery = new DiscoveryConfiguration();
private RlpxConfiguration rlpx = new RlpxConfiguration(); private RlpxConfiguration rlpx = new RlpxConfiguration();
private int initiateConnectionsFrequencySec = DEFAULT_INITIATE_CONNECTIONS_FREQUENCY_SEC; private int initiateConnectionsFrequencySec = DEFAULT_INITIATE_CONNECTIONS_FREQUENCY_SEC;
private int checkMaintainedConnectionsFrequencySec = private int checkMaintainedConnectionsFrequencySec =
DEFAULT_CHECK_MAINTAINED_CONNECTSION_FREQUENCY_SEC; DEFAULT_CHECK_MAINTAINED_CONNECTIONS_FREQUENCY_SEC;
public static NetworkingConfiguration create() { public static NetworkingConfiguration create() {
return new NetworkingConfiguration(); return new NetworkingConfiguration();

Loading…
Cancel
Save