You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
STF enforces a particular order in which we can define a LoadTestProcessDefinition instance. This enforcement can cause STF test plugins to become complicated (or less simple than what is desirable). For example:
LoadTestProcessDefinition loadTestInvocation = test.createLoadTestSpecification()
.addJvmOption("-Djava.classloading.dir=" + notonclasspathDirRoot) // Expose the bin_notonclasspath root directory to the deadlock test
.addJvmOption("-Djava.version.number=" + javaVersion)
.addModules(modulesAdd)
.addPrereqJarToClasspath(JavaProcessDefinition.JarId.JUNIT)
.addPrereqJarToClasspath(JavaProcessDefinition.JarId.HAMCREST)
.addProjectToClasspath("openjdk.test.classloading");
if (isTimeBasedLoadTest) {
loadTestInvocation = loadTestInvocation.setTimeLimit(timeLimit); // If it's a time based test, stop execution after given time duration
}
loadTestInvocation = loadTestInvocation.setAbortIfOutOfMemory(false)
.addSuite("classloading")
.setSuiteThreadCount(cpuCount - 1, 10)
.setSuiteInventory(inventoryFile);
if (!isTimeBasedLoadTest) {
loadTestInvocation = loadTestInvocation.setSuiteNumTests(totalTests * testCountMultiplier);
}
loadTestInvocation = loadTestInvocation.setSuiteRandomSelection();
The above definition could be simpler, if STF allowed the following:
LoadTestProcessDefinition loadTestInvocation = test.createLoadTestSpecification()
.addJvmOption("-Djava.classloading.dir=" + notonclasspathDirRoot) // Expose the bin_notonclasspath root directory to the deadlock test
.addJvmOption("-Djava.version.number=" + javaVersion)
.addModules(modulesAdd)
.addPrereqJarToClasspath(JavaProcessDefinition.JarId.JUNIT)
.addPrereqJarToClasspath(JavaProcessDefinition.JarId.HAMCREST)
.addProjectToClasspath("openjdk.test.classloading")
.setAbortIfOutOfMemory(false)
.addSuite("classloading");
if (isTimeBasedLoadTest) {
loadTestInvocation = loadTestInvocation.setTimeLimit(timeLimit); // If it's a time based test, stop execution after given time duration
} else {
loadTestInvocation = loadTestInvocation.setSuiteNumTests(totalTests * testCountMultiplier);
}
loadTestInvocation = loadTestInvocation.setSuiteThreadCount(cpuCount - 1, 10)
.setSuiteInventory(inventoryFile)
.setSuiteRandomSelection();
This issue is opened to revisit the design principles of these order enforcements and update the logic therein if possible.
STF enforces a particular order in which we can define a
LoadTestProcessDefinition
instance. This enforcement can cause STF test plugins to become complicated (or less simple than what is desirable). For example:The above definition could be simpler, if STF allowed the following:
This issue is opened to revisit the design principles of these order enforcements and update the logic therein if possible.
FYI @llxia
The text was updated successfully, but these errors were encountered: