Helper class for kicking off forked JVM processes, helpful in managing the setup and execution of the forked process. Subclasses should provided a static void main method.
Modifiers | Name | Description |
---|---|---|
static class |
ForkedGrailsProcess.TextDumper |
Modifiers | Name | Description |
---|---|---|
static java.lang.String |
DEBUG_FORK |
|
static int |
DEFAULT_DAEMON_PORT |
|
static java.lang.String |
DEFAULT_DEBUG_ARGS |
|
static java.lang.String |
PARENT_PROCESS_PORT |
Type | Name and description |
---|---|
boolean |
daemon |
int |
daemonPort |
boolean |
debug |
java.lang.String |
debugArgs |
java.lang.String |
encoding |
ExecutionContext |
executionContext |
boolean |
forkReserve |
java.net.URLClassLoader |
forkedClassLoader |
java.util.List<java.lang.String> |
jvmArgs |
int |
maxMemory |
int |
maxPerm |
int |
minMemory |
boolean |
reloading |
java.io.File |
reloadingAgent |
Constructor and description |
---|
ForkedGrailsProcess
() |
Type Params | Return Type | Name and description |
---|---|---|
|
protected java.lang.Process |
attachOutputListener(java.lang.Process process, boolean async = false) |
|
protected java.util.List<java.io.File> |
buildMinimalIsolatedClasspath(BuildSettings buildSettings) |
|
protected java.util.List<java.lang.String> |
buildProcessCommand(ExecutionContext executionContext, java.lang.String classpathString, boolean isReserve = false, boolean isDaemon = false) |
|
void |
configure(java.util.Map forkConfig) |
|
protected void |
configureFork(BuildSettings buildSettings) |
|
protected groovy.lang.GroovyClassLoader |
createClassLoader(BuildSettings buildSettings) |
|
protected void |
discoverAndSetAgent(ExecutionContext executionContext) |
|
protected java.io.File |
findJarFile(java.lang.Class targetClass) |
|
java.util.Collection<java.io.File> |
findSystemClasspathJars(BuildSettings buildSettings) |
|
protected java.io.File |
findToolsJar() |
|
java.lang.Process |
fork(java.util.Map argsMap = new LinkedHashMap() |
|
void |
forkDaemon(ExecutionContext executionContext = getExecutionContext() |
|
void |
forkReserve(ExecutionContext executionContext = getExecutionContext() |
|
protected void |
forkReserveProcess(java.util.List<java.lang.String> cmd, ExecutionContext executionContext, boolean attachListener = true) |
|
protected java.lang.String |
getBoostrapClasspath(ExecutionContext executionContext) |
|
protected java.io.File |
getResumeDir() |
|
protected BuildSettings |
initializeBuildSettings(ExecutionContext ec) |
|
protected java.net.URLClassLoader |
initializeClassLoader(BuildSettings buildSettings) |
|
protected void |
initializeLogging(java.io.File grailsHome, java.lang.ClassLoader classLoader) |
|
protected boolean |
isDaemonProcess() @return Whether this process should be launched using a running daemon process. |
|
boolean |
isDaemonRunning() |
|
protected boolean |
isDebugForkEnabled() |
|
boolean |
isForkingReserveEnabled() |
|
protected boolean |
isReserveProcess()
|
|
boolean |
isServerRunning(int port) @return Whether the server is running |
|
protected boolean |
isWindows() |
|
void |
killAfterTimeout() |
|
ExecutionContext |
readExecutionContext() |
|
protected ExecutionContext |
readExecutionContext(java.lang.String location) |
|
static java.lang.String |
readLine(java.io.InputStream inputStream) |
|
void |
restartDaemon(ExecutionContext executionContext = getExecutionContext() |
|
protected void |
runDaemonCommand(java.lang.String daemonCmd) |
|
protected void |
setupReloading(java.net.URLClassLoader classLoader, BuildSettings buildSettings) @param classLoader |
|
protected boolean |
shouldRunWithDaemon() |
|
void |
startDaemon(groovy.lang.Closure callable) |
|
protected void |
startParentAvailabilityServer() |
|
protected void |
startParentPortMonitor() |
|
protected void |
startProjectWatcher(java.net.URLClassLoader classLoader, BuildSettings buildSettings) |
|
protected java.io.File |
storeExecutionContext(ExecutionContext executionContext) |
|
protected void |
waitForResume() |
Methods inherited from class | Name |
---|---|
class java.lang.Object |
java.lang.Object#wait(long, int), java.lang.Object#wait(long), java.lang.Object#wait(), java.lang.Object#equals(java.lang.Object), java.lang.Object#toString(), java.lang.Object#hashCode(), java.lang.Object#getClass(), java.lang.Object#notify(), java.lang.Object#notifyAll() |
Groovy Documentation