diff --git a/utbot-framework-api/src/main/kotlin/org/utbot/framework/UtSettings.kt b/utbot-framework-api/src/main/kotlin/org/utbot/framework/UtSettings.kt index 0bcfd29bd7..fdb15e4bc6 100644 --- a/utbot-framework-api/src/main/kotlin/org/utbot/framework/UtSettings.kt +++ b/utbot-framework-api/src/main/kotlin/org/utbot/framework/UtSettings.kt @@ -308,6 +308,12 @@ object UtSettings : AbstractSettings(logger, defaultKeyForSettingsPath, defaultS */ var engineProcessLogConfigFile by getStringProperty("") + /** + * Optional arguments to the engine java process. One may want to + * increase heap size in order to give Soot more room for analysis. + */ + var engineProcessJavaOptionalArguments by getStringProperty("") + /** * The property is useful only for the IntelliJ IDEs. * If the property is set in true the engine process opens a debug port. diff --git a/utbot-framework-api/src/main/kotlin/org/utbot/framework/process/AbstractRDProcessCompanion.kt b/utbot-framework-api/src/main/kotlin/org/utbot/framework/process/AbstractRDProcessCompanion.kt index 41b0499cae..dab6e39492 100644 --- a/utbot-framework-api/src/main/kotlin/org/utbot/framework/process/AbstractRDProcessCompanion.kt +++ b/utbot-framework-api/src/main/kotlin/org/utbot/framework/process/AbstractRDProcessCompanion.kt @@ -1,6 +1,7 @@ package org.utbot.framework.process import org.utbot.common.osSpecificJavaExecutable +import org.utbot.framework.UtSettings import org.utbot.framework.plugin.services.JdkInfoService import org.utbot.rd.rdPortArgument import java.io.File @@ -26,12 +27,15 @@ abstract class AbstractRDProcessCompanion( val debugArgument = "-agentlib:jdwp=transport=dt_socket,server=n,suspend=${suspendValue},quiet=y,address=$debugPort" .takeIf { runWithDebug } - add(javaExecutablePathString.pathString) val javaVersionSpecificArgs = OpenModulesContainer.javaVersionSpecificArguments if (javaVersionSpecificArgs.isNotEmpty()) { addAll(javaVersionSpecificArgs) } + UtSettings.engineProcessJavaOptionalArguments.split("\\s+".toRegex()). + takeIf {it.size > 1 || it[0].isNotEmpty() }?.forEach { + add(it) + } debugArgument?.let { add(it) } } } \ No newline at end of file