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-benchmarks.git
The following commit(s) were added to refs/heads/develop by this push: new 5b23f49 GEODE-6116: Set JVM flags on the VMs. (#12) 5b23f49 is described below commit 5b23f498be1ab99b09f726de19029187175b392a Author: Nabarun Nag <nabarun...@users.noreply.github.com> AuthorDate: Fri Nov 30 16:41:12 2018 -0800 GEODE-6116: Set JVM flags on the VMs. (#12) --- .../benchmark/configurations/JVMProperties.java | 46 ++++++++++++++++++++++ .../geode/benchmark/tests/BenchmarkOperation.java | 11 ++++-- 2 files changed, 53 insertions(+), 4 deletions(-) diff --git a/geode-benchmarks/src/main/java/org/apache/geode/benchmark/configurations/JVMProperties.java b/geode-benchmarks/src/main/java/org/apache/geode/benchmark/configurations/JVMProperties.java new file mode 100644 index 0000000..f9695f2 --- /dev/null +++ b/geode-benchmarks/src/main/java/org/apache/geode/benchmark/configurations/JVMProperties.java @@ -0,0 +1,46 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more contributor license + * agreements. See the NOTICE file distributed with this work for additional information regarding + * copyright ownership. The ASF licenses this file to You under the Apache License, Version 2.0 (the + * "License"); you may not use this file except in compliance with the License. You may obtain a + * copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software distributed under the License + * is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express + * or implied. See the License for the specific language governing permissions and limitations under + * the License. + */ +package org.apache.geode.benchmark.configurations; + +public class JVMProperties { + + public static final String[] JVM_ARGS = new String[] { + "-XX:CMSInitiatingOccupancyFraction=60", + "-XX:+PrintGCDetails", + "-XX:+PrintGCTimeStamps", + "-XX:+PrintGCDateStamps", + "-XX:+PrintGCApplicationStoppedTime", + "-XX:+PrintGCApplicationConcurrentTime", + "-XX:+UseGCLogFileRotation", + "-XX:NumberOfGCLogFiles=20", + "-XX:GCLogFileSize=1M", + "-XX:+UnlockDiagnosticVMOptions", + "-XX:ParGCCardsPerStrideChunk=32768", + "-XX:OnOutOfMemoryError='\''kill -9 %p'\''", + "-XX:+UseNUMA", + "-XX:+UseConcMarkSweepGC", + "-XX:+UseCMSInitiatingOccupancyOnly", + "-XX:+CMSClassUnloadingEnabled", + "-XX:+DisableExplicitGC", + "-XX:+ScavengeBeforeFullGC", + "-XX:+CMSScavengeBeforeRemark", + "-server", + "-Djava.awt.headless=true", + "-Dsun.rmi.dgc.server.gcInterval=9223372036854775806", + "-Dgemfire.OSProcess.ENABLE_OUTPUT_REDIRECTION=true", + "-Dgemfire.launcher.registerSignalHandlers=true" + }; + +} diff --git a/geode-benchmarks/src/main/java/org/apache/geode/benchmark/tests/BenchmarkOperation.java b/geode-benchmarks/src/main/java/org/apache/geode/benchmark/tests/BenchmarkOperation.java index 5afbf29..95cb91d 100644 --- a/geode-benchmarks/src/main/java/org/apache/geode/benchmark/tests/BenchmarkOperation.java +++ b/geode-benchmarks/src/main/java/org/apache/geode/benchmark/tests/BenchmarkOperation.java @@ -21,6 +21,7 @@ import static org.apache.geode.benchmark.configurations.BenchmarkParameters.Role import static org.apache.geode.benchmark.configurations.BenchmarkParameters.Roles.LOCATOR; import static org.apache.geode.benchmark.configurations.BenchmarkParameters.Roles.SERVER; import static org.apache.geode.benchmark.configurations.BenchmarkParameters.WARM_UP_TIME; +import static org.apache.geode.benchmark.configurations.JVMProperties.JVM_ARGS; import org.junit.Test; @@ -34,8 +35,6 @@ import org.apache.geode.perftest.TestRunners; public abstract class BenchmarkOperation { long keyRange = KEY_RANGE; - int warmUpTime = WARM_UP_TIME; - int benchmarkDuration = BENCHMARK_DURATION; @Test public void run() throws Exception { @@ -58,11 +57,14 @@ public abstract class BenchmarkOperation { config.name(this.getClass().getCanonicalName()); - config.warmupSeconds(warmUpTime); - config.durationSeconds(benchmarkDuration); + config.warmupSeconds(WARM_UP_TIME); + config.durationSeconds(BENCHMARK_DURATION); config.role(LOCATOR, 1); config.role(SERVER, 2); config.role(CLIENT, 1); + config.jvmArgs(SERVER, JVM_ARGS); + config.jvmArgs(CLIENT, JVM_ARGS); + config.jvmArgs(LOCATOR, JVM_ARGS); config.before(new StartLocator(locatorPort), LOCATOR); config.before(new StartServer(locatorPort), SERVER); createRegion(config); @@ -70,6 +72,7 @@ public abstract class BenchmarkOperation { config.before(new CreateClientProxyRegion(), CLIENT); config.before(new PrePopulateRegion(keyRange), SERVER); benchmarkOperation(config); + } /**