Description
This synchronized block is protecting lastSentTime which is a native long. Can use AtomicLong and remove this synchronization.
synchronized boolean packetSentInTime() { long diff = Time.monotonicNow() - lastSentTime; if (diff > maxSendIdleTime) { LOG.info("A packet was last sent " + diff + " milliseconds ago."); return false; } return true; }
Attachments
Attachments
Issue Links
- links to