Logo Search packages:      
Sourcecode: libjgroups-java version File versions

org::jgroups::protocols::pbcast::NAKACK Class Reference

Inheritance diagram for org::jgroups::protocols::pbcast::NAKACK:

org::jgroups::stack::Protocol org::jgroups::stack::Retransmitter::RetransmitCommand

List of all members.

Detailed Description

Negative AcKnowledgement layer (NAKs). Messages are assigned a monotonically increasing sequence number (seqno). Receivers deliver messages ordered according to seqno and request retransmission of missing messages.
Retransmit requests are usually sent to the original sender of a message, but this can be changed by xmit_from_random_member (send to random member) or use_mcast_xmit_req (send to everyone). Responses can also be sent to everyone instead of the requester by setting use_mcast_xmit to true.

Bela Ban
NAKACK.java,v 2008/06/20 15:22:32 vlada Exp

Definition at line 35 of file NAKACK.java.

Public Member Functions

void destroy ()
Object down (Event evt)
boolean downThreadEnabled ()
Map< String, Object > dumpStats ()
void enableStats (boolean flag)
double getAverageLossRate ()
double getAverageSmoothedLossRate ()
Protocol getDownProtocol ()
int getGcLag ()
int getMaxXmitBufSize ()
long getMaxXmitSize ()
long getMissingMessagesReceived ()
String getName ()
int getPendingRetransmissionRequests ()
Properties getProperties ()
ProtocolStack getProtocolStack ()
int getReceivedTableSize ()
double getSmoothedAverageRetransmissionTime (Address sender)
ThreadFactory getThreadFactory ()
double getTotalAverageRetransmissionTime ()
double getTotalAverageSmoothedRetransmissionTime ()
Protocol getUpProtocol ()
long getXmitRequestsReceived ()
long getXmitRequestsSent ()
long getXmitResponsesReceived ()
long getXmitResponsesSent ()
int getXmitTableSize ()
void init () throws Exception
boolean isDiscardDeliveredMsgs ()
boolean isUseMcastXmit ()
boolean isXmitFromRandomMember ()
void messageGapDetected (long from, long to, Address src)
void missingMessageReceived (long seqno, Address original_sender)
String printLossRates ()
String printMessages ()
String printRetransmissionAvgs ()
String printRetransmissionTimes ()
String printSmoothedRetransmissionAvgs ()
String printStabilityHistory ()
String printStabilityMessages ()
String printStats ()
Vector< Integer > providedDownServices ()
Vector< Integer > providedUpServices ()
Vector< Integer > requiredDownServices ()
Vector< Integer > requiredUpServices ()
void resetStats ()
void retransmit (long first_seqno, long last_seqno, Address sender)
void setDiscardDeliveredMsgs (boolean discard_delivered_msgs)
void setDownProtocol (Protocol down_prot)
void setGcLag (int gc_lag)
void setMaxXmitBufSize (int max_xmit_buf_size)
void setMaxXmitSize (long max_xmit_size)
boolean setProperties (Properties props)
boolean setPropertiesInternal (Properties props)
void setProtocolStack (ProtocolStack stack)
void setUpProtocol (Protocol up_prot)
void setUseMcastXmit (boolean use_mcast_xmit)
void setXmitFromRandomMember (boolean xmit_from_random_member)
void start () throws Exception
boolean statsEnabled ()
void stop ()
Object up (Event evt)
boolean upThreadEnabled ()

Protected Member Functions

TP getTransport ()
void retransmit (long first_seqno, long last_seqno, Address sender, boolean multicast_xmit_request)

Protected Attributes

Protocol down_prot = null
final Log log = LogFactory.getLog(this.getClass())
boolean print_stability_history_on_failed_xmit = false
final Properties props = new Properties()
ProtocolStack stack = null
boolean stats = true
Protocol up_prot = null

Private Member Functions

void adjustReceivers (List< Address > new_members)
void cancelRebroadcasting ()
void clear ()
NakReceiverWindow createNakReceiverWindow (Address sender, long initial_seqno, long lowest_seqno)
void dumpXmitStats (String filename) throws IOException
Digest getDigest ()
Digest.Entry getEntry (Address sender)
void handleMessage (Message msg, NakAckHeader hdr)
void handleXmitReq (Address xmit_requester, long first_seqno, long last_seqno, Address original_sender)
void handleXmitRsp (Message msg)
void mergeDigest (Digest digest)
void rebroadcastMessages ()
void reset ()
void send (Event evt, Message msg)
void sendXmitRsp (Address dest, Message msg, long seqno)
void setDigest (Digest digest)
void stable (Digest digest)

Static Private Member Functions

static void updateStats (Map< Address, StatsEntry > map, Address key, int req, int rsp, int missing)

Private Attributes

boolean discard_delivered_msgs = false
boolean eager_lock_release = true
long exponential_backoff = 0
int gc_lag = 20
boolean is_server = false
boolean leaving = false
Address local_addr = null
Map< Thread, ReentrantLock > locks
long max_rebroadcast_timeout = 2000
int max_xmit_buf_size = 0
final List< Addressmembers = new CopyOnWriteArrayList<Address>()
long missing_msgs_received
final Set< Long > oob_loopback_msgs = Collections.synchronizedSet(new HashSet<Long>())
Digest rebroadcast_digest = null
final Lock rebroadcast_digest_lock = new ReentrantLock()
final Condition rebroadcast_done = rebroadcast_lock.newCondition()
final Lock rebroadcast_lock = new ReentrantLock()
volatile boolean rebroadcasting = false
BoundedList< MissingMessage > receive_history
Map< Address, StatsEntry > received = new ConcurrentHashMap<Address,StatsEntry>()
long[] retransmit_timeouts = {600, 1200, 2400, 4800}
BoundedList< XmitRequest > send_history
Map< Address, StatsEntry > sent = new ConcurrentHashMap<Address,StatsEntry>()
long seqno = 0
final Lock seqno_lock = new ReentrantLock()
final Map< Address, Double > smoothed_avg_xmit_times = new HashMap<Address,Double>()
final BoundedList< Digeststability_msgs = new BoundedList<Digest>(10)
boolean started = false
int stats_list_size = 20
TimeScheduler timer = null
final AtomicInteger undelivered_msgs = new AtomicInteger(0)
boolean use_mcast_xmit = true
boolean use_mcast_xmit_req = false
boolean use_stats_for_retransmission = false
View view
boolean xmit_from_random_member = false
int xmit_history_max_size = 50
long xmit_reqs_received
long xmit_reqs_sent
long xmit_rsps_received
long xmit_rsps_sent
final ConcurrentMap< Address,
ConcurrentMap< Long, Long > > 
xmit_stats = new ConcurrentHashMap<Address,ConcurrentMap<Long,Long>>()
final ConcurrentMap< Address,
xmit_table = new ConcurrentHashMap<Address,NakReceiverWindow>(11)
ConcurrentMap< Long, XmitTimeStatxmit_time_stats = null
long xmit_time_stats_start
final ConcurrentMap< Address,
BoundedList< Long > > 
xmit_times_history = new ConcurrentHashMap<Address,BoundedList<Long>>()

Static Private Attributes

static final long INITIAL_SEQNO = 0
static final double INITIAL_SMOOTHED_AVG = 30.0
static final String name = "NAKACK"
static final int NUM_REBROADCAST_MSGS = 3
static final double WEIGHT = 0.9


class  ActualInterval
class  MissingMessage
class  StatsEntry
class  XmitRequest
class  XmitTimeStat

The documentation for this class was generated from the following file:

Generated by  Doxygen 1.6.0   Back to index