Class JavaCommandBuilder
java.lang.Object
com.gigaspaces.start.JavaCommandBuilder
- Since:
- 14.0
- Author:
- Niv Ingberg
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionbuild()classpath(Collection<Path> paths) classpathFromEnv(String envVarName) classpathWithJars(Path path) getEnvVarValue(String envVarName) initialHeap(String heap) javaExecutable(String javaExecutable) options(Collection<String> options) optionsFromEnv(String envVarName) optionsFromGsEnv(String envVarSuffix) systemProperty(String key, String value) systemPropertyFromEnv(String key, String envVarName) toArgFileCommandLine(Path dir) Same command astoCommandLine(), but with everything except the java executable moved into a java@argfile(Java 9+) underdir.
-
Constructor Details
-
JavaCommandBuilder
public JavaCommandBuilder()
-
-
Method Details
-
build
-
toProcessBuilder
-
toCommandLine
-
toArgFileCommandLine
Same command astoCommandLine(), but with everything except the java executable moved into a java@argfile(Java 9+) underdir. Used on Windows when the command line is too long for cmd.exe (8191 chars) - gs.bat runs the generated command throughset GS_COMMAND=..., and a long GS_HOME (e.g. a zip extracted under a deep folder) is repeated in every classpath entry. The file name is a hash of its content, so starting the same service again reuses the same file instead of accumulating new ones.- Throws:
IOException
-
javaExecutable
-
mainClass
-
classpath
-
classpath
-
classpath
-
classpathWithJars
-
classpathFromEnv
-
systemProperty
-
option
-
options
-
optionsFromEnv
-
optionsFromGsEnv
-
systemPropertyFromEnv
-
getEnvVarValue
-
heap
-
initialHeap
-
maxHeap
-
arg
-
getDefaultJavaWindowsExecutable
-