This is an automated email from the ASF dual-hosted git repository.
upthewaterspout pushed a commit to branch develop
in repository https://gitbox.apache.org/repos/asf/geode.git
The following commit(s) were added to refs/heads/develop by this push:
new efb2e29 GEODE-5765: Clean up soft references faster in dunit tests
efb2e29 is described below
commit efb2e291ec1284731ea6d21fbc988d9060b7eed7
Author: Dan Smith <[email protected]>
AuthorDate: Thu Sep 20 10:26:00 2018 -0700
GEODE-5765: Clean up soft references faster in dunit tests
We observed that several tests in AlterRuntimeCommandDUnitTest class
were taking minutes when they should be taking a few seconds at most.
After some debugging, we determined that the JVM itself is struggling to
deal with having 100K+ classes loaded. They are loaded because the test
is repeated starting and stopping the http service, which creates a
classloader and causes soft references to all of the loaded classes to
be cached.
By setting this flag to clear the soft references faster, the test times
go back to normal.
---
.../main/java/org/apache/geode/test/dunit/standalone/ProcessManager.java | 1 +
1 file changed, 1 insertion(+)
diff --git
a/geode-dunit/src/main/java/org/apache/geode/test/dunit/standalone/ProcessManager.java
b/geode-dunit/src/main/java/org/apache/geode/test/dunit/standalone/ProcessManager.java
index fb7f2dd..a200f14 100755
---
a/geode-dunit/src/main/java/org/apache/geode/test/dunit/standalone/ProcessManager.java
+++
b/geode-dunit/src/main/java/org/apache/geode/test/dunit/standalone/ProcessManager.java
@@ -261,6 +261,7 @@ public class ProcessManager {
+ ConfigurationProperties.VALIDATE_SERIALIZABLE_OBJECTS + "=true");
cmds.add("-ea");
cmds.add("-XX:MetaspaceSize=512m");
+ cmds.add("-XX:SoftRefLRUPolicyMSPerMB=1");
cmds.add(agent);
cmds.add(ChildVM.class.getName());
String[] rst = new String[cmds.size()];