Move daemon session flag files to daemon discovery dir by default + minor fixes:
- Move flag files from the temp dir, because right now JPS cleans temp dir on each build start. Should fix KT-15707, also may affect KT-15562.
- change compiler runner to allow the fix above
- Fix flag file name filtering
- Fix ifAlive handling on the new compile method in the daemon.
Original commit: 7c0cdf90cf
This commit is contained in:
@@ -206,10 +206,10 @@ class JpsKotlinCompilerRunner : KotlinCompilerRunner<JpsCompilerEnvironment>() {
|
||||
val libPath = CompilerRunnerUtil.getLibPath(environment.kotlinPaths, environment.messageCollector)
|
||||
val compilerPath = File(libPath, "kotlin-compiler.jar")
|
||||
val compilerId = CompilerId.makeCompilerId(compilerPath)
|
||||
val flagFile = File.createTempFile("kotlin-compiler-jps-session-", "-is-running").apply {
|
||||
deleteOnExit()
|
||||
}
|
||||
jpsDaemonConnection = newDaemonConnection(compilerId, flagFile, environment)
|
||||
// TODO: pass daemon options to newDaemonConnection
|
||||
val daemonOptions = configureDaemonOptions()
|
||||
val flagFile = makeAutodeletingFlagFile("compiler-jps-session-", File(daemonOptions.runFilesPathOrDefault))
|
||||
jpsDaemonConnection = newDaemonConnection(compilerId, flagFile, environment, daemonOptions)
|
||||
}
|
||||
return jpsDaemonConnection!!
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user