mirror of
https://github.com/usatiuk/dhfs.git
synced 2025-10-29 04:57:48 +01:00
little fixes 2
This commit is contained in:
@@ -66,13 +66,13 @@ public class InvalidationQueueService {
|
||||
remoteObjectServiceClient.notifyUpdate(forHost.getKey(), obj);
|
||||
sent++;
|
||||
} catch (Exception e) {
|
||||
if (e.getCause().getClass().equals(InterruptedException.class)) {
|
||||
Log.info("Invalidation sender exiting");
|
||||
return;
|
||||
}
|
||||
Log.info("Failed to send invalidation to " + forHost.getKey() + " of " + obj + ": " + e.getMessage() + " will retry");
|
||||
pushInvalidationToOne(forHost.getKey(), obj);
|
||||
}
|
||||
if (Thread.interrupted()) {
|
||||
Log.info("Invalidation sender exiting");
|
||||
return;
|
||||
}
|
||||
}
|
||||
stats += forHost.getKey() + ": " + sent + " ";
|
||||
}
|
||||
|
||||
@@ -120,7 +120,7 @@ public class RemoteHostManager {
|
||||
// FIXME:
|
||||
private boolean reachable(HostInfo hostInfo) {
|
||||
try {
|
||||
return withClient(hostInfo.getAddr(), hostInfo.getPort(), Optional.of(30000L /*ms*/), c -> {
|
||||
return withClient(hostInfo.getAddr(), hostInfo.getPort(), Optional.of(5000L /*ms*/), c -> {
|
||||
var ret = c.ping(PingRequest.newBuilder().setSelfname(selfname).build());
|
||||
if (!ret.getSelfname().equals(hostInfo.getName())) {
|
||||
throw new IllegalStateException("Ping selfname returned " + ret.getSelfname() + " but expected " + hostInfo.getName());
|
||||
|
||||
Reference in New Issue
Block a user