db-derby-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From kahat...@apache.org
Subject svn commit: r1464470 - in /db/derby/code/trunk/java/testing/org/apache/derbyTesting/functionTests/tests/memory: BlobMemTest.java ClobMemTest.java
Date Thu, 04 Apr 2013 11:42:01 GMT
Author: kahatlen
Date: Thu Apr  4 11:42:00 2013
New Revision: 1464470

URL: http://svn.apache.org/r1464470
Log:
DERBY-6096: Only run gc if debug output has been requested

Modified:
    db/derby/code/trunk/java/testing/org/apache/derbyTesting/functionTests/tests/memory/BlobMemTest.java
    db/derby/code/trunk/java/testing/org/apache/derbyTesting/functionTests/tests/memory/ClobMemTest.java

Modified: db/derby/code/trunk/java/testing/org/apache/derbyTesting/functionTests/tests/memory/BlobMemTest.java
URL: http://svn.apache.org/viewvc/db/derby/code/trunk/java/testing/org/apache/derbyTesting/functionTests/tests/memory/BlobMemTest.java?rev=1464470&r1=1464469&r2=1464470&view=diff
==============================================================================
--- db/derby/code/trunk/java/testing/org/apache/derbyTesting/functionTests/tests/memory/BlobMemTest.java
(original)
+++ db/derby/code/trunk/java/testing/org/apache/derbyTesting/functionTests/tests/memory/BlobMemTest.java
Thu Apr  4 11:42:00 2013
@@ -350,10 +350,12 @@ public class BlobMemTest extends BaseJDB
         // just a single fetch will build the hash table and consume the memory.
         assertTrue(rs.next());
         // derby.tests.debug prints memory usage
-        System.gc();
-        println("TotalMemory:" + Runtime.getRuntime().totalMemory()
-                + " " + "Free Memory:"
-                + Runtime.getRuntime().freeMemory());
+        if (TestConfiguration.getCurrent().isVerbose()) {
+            System.gc();
+            println("TotalMemory:" + Runtime.getRuntime().totalMemory()
+                    + " " + "Free Memory:"
+                    + Runtime.getRuntime().freeMemory());
+        }
         rs.close();
     }
 

Modified: db/derby/code/trunk/java/testing/org/apache/derbyTesting/functionTests/tests/memory/ClobMemTest.java
URL: http://svn.apache.org/viewvc/db/derby/code/trunk/java/testing/org/apache/derbyTesting/functionTests/tests/memory/ClobMemTest.java?rev=1464470&r1=1464469&r2=1464470&view=diff
==============================================================================
--- db/derby/code/trunk/java/testing/org/apache/derbyTesting/functionTests/tests/memory/ClobMemTest.java
(original)
+++ db/derby/code/trunk/java/testing/org/apache/derbyTesting/functionTests/tests/memory/ClobMemTest.java
Thu Apr  4 11:42:00 2013
@@ -294,10 +294,12 @@ public class ClobMemTest extends BaseJDB
         // just a single fetch will build the hash table and consume the memory.
         assertTrue(rs.next());
         // derby.tests.debug prints memory usage
-        System.gc();
-        println("TotalMemory:" + Runtime.getRuntime().totalMemory()
-                + " " + "Free Memory:"
-                + Runtime.getRuntime().freeMemory());
+        if (TestConfiguration.getCurrent().isVerbose()) {
+            System.gc();
+            println("TotalMemory:" + Runtime.getRuntime().totalMemory()
+                    + " " + "Free Memory:"
+                    + Runtime.getRuntime().freeMemory());
+        }
         rs.close();
     }
 }



Mime
View raw message