}
}
+ long backendSilentTicks(final long now) {
+ return now - lastReceivedTicks;
+ }
+
/*
* We are using tri-state return here to indicate one of three conditions:
* - if there is no timeout to schedule, return Optional.empty()
return Optional.empty();
}
- final long backendSilentTicks = now - lastReceivedTicks;
+ final long backendSilentTicks = backendSilentTicks(now);
if (backendSilentTicks >= BACKEND_ALIVE_TIMEOUT_NANOS) {
LOG.debug("Connection {} has not seen activity from backend for {} nanoseconds, timing out", this,
backendSilentTicks);