From 7d336c98e4e2400ee04bde628f2538300357208a Mon Sep 17 00:00:00 2001 From: akwizgran Date: Thu, 19 May 2022 14:19:41 +0100 Subject: [PATCH] Raise stability threshold and poll less often when network is stable. --- .../java/org/briarproject/bramble/plugin/tor/TorPlugin.java | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/bramble-core/src/main/java/org/briarproject/bramble/plugin/tor/TorPlugin.java b/bramble-core/src/main/java/org/briarproject/bramble/plugin/tor/TorPlugin.java index c3cf2db8e..7b5ba5302 100644 --- a/bramble-core/src/main/java/org/briarproject/bramble/plugin/tor/TorPlugin.java +++ b/bramble-core/src/main/java/org/briarproject/bramble/plugin/tor/TorPlugin.java @@ -129,7 +129,7 @@ abstract class TorPlugin implements DuplexPlugin, EventHandler, EventListener { * After this many consecutive successful connections to our own hidden * service we consider the network to be stable. */ - private static final int STABLE_NETWORK_THRESHOLD = 3; + private static final int STABLE_NETWORK_THRESHOLD = 10; /** * After this many consecutive failed connections to our own hidden service @@ -142,7 +142,7 @@ abstract class TorPlugin implements DuplexPlugin, EventHandler, EventListener { * to be stable. */ private static final int POLLING_INTERVAL_STABLE = - (int) MINUTES.toMillis(5); + (int) MINUTES.toMillis(10); /** * How often to poll our own hidden service and our contacts' hidden