[Swift-commit] cog r4004

swift at ci.uchicago.edu swift at ci.uchicago.edu
Fri Jul 4 02:15:04 CDT 2014


------------------------------------------------------------------------
r4004 | hategan | 2014-07-04 02:14:31 -0500 (Fri, 04 Jul 2014) | 1 line

only output diagnostic messages if at least one byte was sent/received
------------------------------------------------------------------------
Index: modules/provider-coaster/src/org/globus/cog/coaster/channels/PerformanceDiagnosticOutputStream.java
===================================================================
--- modules/provider-coaster/src/org/globus/cog/coaster/channels/PerformanceDiagnosticOutputStream.java	(revision 4003)
+++ modules/provider-coaster/src/org/globus/cog/coaster/channels/PerformanceDiagnosticOutputStream.java	(working copy)
@@ -28,7 +28,7 @@
 		Timer.every(1000, new Runnable() {
 			public void run() {
 				count += 1;
-				if (count % INTERVAL == 0) {
+				if (count % INTERVAL == 0 && getTotal() > 0) {
     				String s;
     				logger.info(s = "[OUT] Total transferred: "
     						+ units(getTotal()) + "B, current rate: "
Index: modules/provider-coaster/src/org/globus/cog/coaster/channels/PerformanceDiagnosticInputStream.java
===================================================================
--- modules/provider-coaster/src/org/globus/cog/coaster/channels/PerformanceDiagnosticInputStream.java	(revision 4003)
+++ modules/provider-coaster/src/org/globus/cog/coaster/channels/PerformanceDiagnosticInputStream.java	(working copy)
@@ -29,16 +29,11 @@
 		Timer.every(1000, new Runnable() {
 			public void run() {
 				count += 1;
-				if (count % INTERVAL == 0) {
+				if (count % INTERVAL == 0 && getTotal() > 0) {
     				String s;
     				logger.info(s = "[IN] Total transferred: " + units(getTotal()) + "B, current rate: "
     						+ units(getCurrentRate()) + "B/s, average rate: " + units(getAverageRate())
     						+ "B/s");
-    				logger.info(s = "[MEM] Heap total: "
-    						+ units(Runtime.getRuntime().totalMemory())
-    						+ "B, Heap used: "
-    						+ units(Runtime.getRuntime().totalMemory()
-    								- Runtime.getRuntime().freeMemory()) + "B");
 				}
 				last = bytes;
 			}



More information about the Swift-commit mailing list