ProgressTracker: Decrease delay due nearestAllowed
[controller.git] / opendaylight / md-sal / cds-access-client / src / main / java / org / opendaylight / controller / cluster / access / client / TransmitQueue.java
index b7543410cd1a63128ac2da7ffde001cc9b3d778f..6f283f549cbdbdf50c75d99397fd650a2b709897 100644 (file)
@@ -174,7 +174,7 @@ abstract class TransmitQueue {
     }
 
     private void transmitEntry(final ConnectionEntry entry, final long now) {
-        LOG.debug("Queue {} transmitting entry {}", entry);
+        LOG.debug("Queue {} transmitting entry {}", this, entry);
         // We are not thread-safe and are supposed to be externally-guarded,
         // hence send-before-record should be fine.
         // This needs to be revisited if the external guards are lowered.
@@ -188,6 +188,7 @@ abstract class TransmitQueue {
      */
     final long enqueue(final ConnectionEntry entry, final long now) {
         if (successor != null) {
+            // This call will pay the enqueuing price, hence the caller does not have to
             successor.forwardEntry(entry, now);
             return 0;
         }
@@ -245,7 +246,7 @@ abstract class TransmitQueue {
     }
 
     final void setForwarder(final ReconnectForwarder forwarder, final long now) {
-        Verify.verify(successor == null, "Successor {} already set on connection {}", successor, this);
+        Verify.verify(successor == null, "Successor %s already set on connection %s", successor, this);
         successor = Preconditions.checkNotNull(forwarder);
         LOG.debug("Connection {} superseded by {}, splicing queue", this, successor);
 
@@ -257,14 +258,14 @@ abstract class TransmitQueue {
         int count = 0;
         ConnectionEntry entry = inflight.poll();
         while (entry != null) {
-            successor.forwardEntry(entry, now);
+            successor.replayEntry(entry, now);
             entry = inflight.poll();
             count++;
         }
 
         entry = pending.poll();
         while (entry != null) {
-            successor.forwardEntry(entry, now);
+            successor.replayEntry(entry, now);
             entry = pending.poll();
             count++;
         }