Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with HTTPS or Subversion.

Download ZIP
Browse files

added JMX information on RetransmiTable to NAKACK

  • Loading branch information...
commit 6f0186990323038b36b1c0d6385e5e6a020ffb98 1 parent 0b26f95
@belaban authored
View
12 src/org/jgroups/protocols/pbcast/NAKACK.java
@@ -473,6 +473,18 @@ public String printLossRates() {
return sb.toString();
}
+ @ManagedOperation(description="Returns the sizes of all NakReceiverWindow.RetransmitTables")
+ public String printRetransmitTableSizes() {
+ StringBuilder sb=new StringBuilder();
+ for(Map.Entry<Address,NakReceiverWindow> entry: xmit_table.entrySet()) {
+ NakReceiverWindow win=entry.getValue();
+ sb.append(entry.getKey() + ": ").append(win.getRetransmiTableSize())
+ .append(" (capacity=" + win.getRetransmitTableCapacity() + ")\n");
+ }
+ return sb.toString();
+ }
+
+
@ManagedAttribute
public double getAverageLossRate() {
double retval=0.0;
View
5 src/org/jgroups/stack/NakReceiverWindow.java
@@ -220,6 +220,11 @@ private void setSmoothedLossRate() {
}
+ public int getRetransmiTableSize() {return xmit_table.size();}
+
+ public int getRetransmitTableCapacity() {return xmit_table.capacity();}
+
+
/**
* Adds a message according to its seqno (sequence number).
* <p>
Please sign in to comment.
Something went wrong with that request. Please try again.