cgl.narada.service.reliable.impl
Class NakProcessor

java.lang.Object
  extended by cgl.narada.service.reliable.impl.NakProcessor
All Implemented Interfaces:
RdDebugFlags

public class NakProcessor
extends Object
implements RdDebugFlags

This class is used to ensure that Naks are issued such that the number of retransmissions is very controlled. At any given time for a given template there should be at the most 2 Naks that are operational. We refer to this as previousNak and currentNak.


Field Summary
 
Fields inherited from interface cgl.narada.service.reliable.impl.RdDebugFlags
InvoicerThread_Debug, NakProcessor_Debug, PublisherPercolator_Debug, RdEntityActuatorImpl_Debug, RdFragmentationHelper_Debug, RdPublishingEntityImpl_Debug, SubscriberPercolator_Debug
 
Constructor Summary
NakProcessor(int entityId, EventProducer producer)
           
 
Method Summary
 boolean hasPendingNaksToIssue()
          Indicates if there are pending Naks to issue.
 void proceedToIssuePendingNaks()
           
 void processMissedSequence(int templateId, long missedSequence)
           
 void processMissedSequences(int templateId, long[] missedSequences)
          We have to check if the reported missedSequence is contained in either a previously issued Nak or the currentNak that was the last issued Nak.
 void processRetransmittedEvent(RdRetransmissionServiceEvent retransmitEvent)
           
 void processSyncAdvance(int templateId, long syncAdvance)
           
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

NakProcessor

public NakProcessor(int entityId,
                    EventProducer producer)
Method Detail

processMissedSequences

public void processMissedSequences(int templateId,
                                   long[] missedSequences)
We have to check if the reported missedSequence is contained in either a previously issued Nak or the currentNak that was the last issued Nak.


processMissedSequence

public void processMissedSequence(int templateId,
                                  long missedSequence)

processSyncAdvance

public void processSyncAdvance(int templateId,
                               long syncAdvance)

processRetransmittedEvent

public void processRetransmittedEvent(RdRetransmissionServiceEvent retransmitEvent)

hasPendingNaksToIssue

public boolean hasPendingNaksToIssue()
Indicates if there are pending Naks to issue. We need to cycle through the pending sets associated with every templateId and then check if there are any pending sequences.


proceedToIssuePendingNaks

public void proceedToIssuePendingNaks()


For comments and suggestions please send e-mail to The NaradaBrokering Project