Increase max latency of removable drive plugin to 28 days.

This commit is contained in:
akwizgran
2021-07-06 17:18:06 +01:00
parent 07ef73ab56
commit d134a67ee9
54 changed files with 210 additions and 163 deletions

View File

@@ -41,7 +41,7 @@ class JavaBluetoothPlugin extends
SecureRandom secureRandom,
Backoff backoff,
PluginCallback callback,
int maxLatency,
long maxLatency,
int maxIdleTime) {
super(connectionManager, connectionFactory, ioExecutor,
wakefulIoExecutor, secureRandom, backoff, callback,

View File

@@ -58,7 +58,7 @@ public class JavaBluetoothPluginFactory implements DuplexPluginFactory {
}
@Override
public int getMaxLatency() {
public long getMaxLatency() {
return MAX_LATENCY;
}

View File

@@ -50,14 +50,14 @@ class ModemPlugin implements DuplexPlugin, Modem.Callback {
private final ModemFactory modemFactory;
private final SerialPortList serialPortList;
private final PluginCallback callback;
private final int maxLatency;
private final long maxLatency;
private final AtomicBoolean used = new AtomicBoolean(false);
private final PluginState state = new PluginState();
private volatile Modem modem = null;
ModemPlugin(ModemFactory modemFactory, SerialPortList serialPortList,
PluginCallback callback, int maxLatency) {
PluginCallback callback, long maxLatency) {
this.modemFactory = modemFactory;
this.serialPortList = serialPortList;
this.callback = callback;
@@ -70,7 +70,7 @@ class ModemPlugin implements DuplexPlugin, Modem.Callback {
}
@Override
public int getMaxLatency() {
public long getMaxLatency() {
return maxLatency;
}

View File

@@ -36,7 +36,7 @@ public class ModemPluginFactory implements DuplexPluginFactory {
}
@Override
public int getMaxLatency() {
public long getMaxLatency() {
return MAX_LATENCY;
}

View File

@@ -33,7 +33,7 @@ abstract class JavaTorPlugin extends TorPlugin {
TorRendezvousCrypto torRendezvousCrypto,
PluginCallback callback,
String architecture,
int maxLatency,
long maxLatency,
int maxIdleTime,
File torDirectory) {
super(ioExecutor, wakefulIoExecutor, networkManager, locationUtils,

View File

@@ -33,7 +33,7 @@ class UnixTorPlugin extends JavaTorPlugin {
TorRendezvousCrypto torRendezvousCrypto,
PluginCallback callback,
String architecture,
int maxLatency,
long maxLatency,
int maxIdleTime,
File torDirectory) {
super(ioExecutor, wakefulIoExecutor, networkManager, locationUtils,

View File

@@ -87,7 +87,7 @@ public class UnixTorPluginFactory implements DuplexPluginFactory {
}
@Override
public int getMaxLatency() {
public long getMaxLatency() {
return MAX_LATENCY;
}