30 Commits

Author SHA1 Message Date
Alexander.Likhachev 58f7dd1c83 [Daemon] Change default Kotlin daemon JVM options
Now, the Kotlin daemon enables parallel GC and uses code cache flushing by default. Also, the default reserved code cache size is adjusted.

^KT-64283 Verification Pending
2024-01-31 15:13:02 +00:00
Ilya Gorbunov d2aae67e03 Replace kotlin-test project dependencies in the project
Use dependency helper function that chooses whether to take them
from the bootstrap repository or from a configuration of kotlin-test

KT-61969
2023-12-13 15:40:25 +00:00
Alexander.Likhachev 8ceee3e8b9 [Daemon] Improve daemon connection algorithm
Before this change, the logic was to find the most suitable daemon and try connecting to it in a loop, ignoring the fact that it could be dying. Now, instead of trying to connect to the daemon dying daemon in a loop, we will make only 1 attemp and then skip if it's already dying.
^KT-55322 In Progress
2023-12-05 13:51:14 +00:00
Alexander.Likhachev 628f6e981d [Daemon] Add test for KT-55322 2023-12-05 13:51:14 +00:00
Alexander.Likhachev b8d1398bdb [Daemon] Use JUnit Vintage engine to run JUnit4 tests 2023-12-05 13:51:14 +00:00
Alexander.Likhachev 357d12fc8e [Build] Move JUnit dependencies into the version catalog
The `kotlin-test` dependencies are left untouched as changing them affects publications, thus these versions are independent from the used inside our build
#KTI-1349 In Progress
2023-09-06 22:47:33 +00:00
Mikhail Glukhikh f9c7a88175 Add -Xuse-fir-lt=false to some scripting tests
make them compatible with K2
2023-08-25 08:57:53 +00:00
Yahor Berdnikau 8f07a9cc61 Cleanup unused Kotlin daemon dependencies 2023-03-02 16:24:54 +01:00
Dmitriy Novozhilov 88efa6bfb6 Update tests after switching to LV 1.9 2023-01-30 09:29:57 +00:00
Andrey Uskov 1550a37b17 Cleanup: remove deprecated methods from Kotlin daemon 2022-12-05 16:02:04 +00:00
Andrey Uskov c9e0100214 Remove experimental implementation of Kotlin Compiler Daemon
#KT-50846 Fixed
2022-12-05 16:02:03 +00:00
Hung Nguyen def886cd31 Clean up fall-back logic in IncrementalCompilerRunner
Make it clear that there 3 distinct cases:
   1. Incremental compilation completed with an ExitCode.
   2. Incremental compilation was not possible for some valid reason
      (e.g., for a clean build), and we will perform non-incremental
      compilation.
   3. Incremental compilation failed with an exception.
      In this case, we will:
        - Print a warning with a stack trace
        - Ask the user to file a bug
        - Collect rebuild reason enum for analytics
           + TODO: Collect the stack trace too
        - Fall back to non-incremental compilation

Test: Existing BaseIncrementalCompilationMultiProjectIT.testFailureHandling_UserError,
      Updated BaseIncrementalCompilationMultiProjectIT.testFailureHandling_ToolError

^KT-53015: In progress
2022-09-19 07:33:16 +03:00
Hung Nguyen e01c2bc651 Warn in Gradle log when incremental compilation fails
When incremental compilation fails, we currently log it at the `debug`
level (and fall back to non-incremental compilation). This commit will
change it to `warning` so that we can get more user reports, which will
allow us to fix the root cause.

Also make sure the warning includes a stack trace.

Additionally, let ReportSeverity.fromCode() return a non-null value
or throw an exception otherwise as that case is not expected.

^KT-52839 In Progress
2022-07-15 10:48:34 +00:00
Vyacheslav Gerasimov f7a9065b75 Build: Use intellij maven repo instead of downloaded IDEA
#KTI-82
2021-12-16 21:48:23 +03:00
Vyacheslav Gerasimov bc2f0936bd Build: Rename commonDep -> commonDependency 2021-12-16 21:48:19 +03:00
Vyacheslav Gerasimov f91d6958a8 Build: Rework runtimeJar helper and drop redundant configuration
#KTI-559
2021-09-26 20:10:29 +03:00
Vyacheslav Gerasimov ab146bd6d4 Build: Fix deprecated Gradle configurations usages
for migration to Gradle 7+ #KTI-559
2021-09-26 18:28:44 +03:00
Alexander Udalov 11902c7f8f Fix warnings in daemon-related modules 2021-08-06 22:36:59 +02:00
Yahor Berdnikau f9ec6bb66a Revert "Optionally make java executable path contribute to the daemon id."
This reverts commit ac86ad252f.
2021-06-18 10:50:21 +00:00
Yahor Berdnikau ac86ad252f Optionally make java executable path contribute to the daemon id.
This change will allow to start Kotlin daemon instances using different
from the current user JDK version and use it to compile Kotlin files.
Old behaviour, when java executable path is not set, is still working
 and still,by default, using current user JDK version.

For example, user for some reason wants to use JDK 1.8 as active one,
 but compile current project using JDK 16.

Main goal is to support Gradle toolchains.

^KT-45611 In Progress
2021-04-24 11:12:47 +03:00
Ilya Gorbunov 81f2aea316 Stabilize existing Path API and annotate with @Throws where appropriate
KT-45913
2021-04-06 14:24:42 +03:00
Alexander Likhachev 70d434e992 Update tests after compiler properties rework
#KT-43605 Fixed
2021-03-04 19:36:18 +03:00
Dmitriy Novozhilov c8f3a4802e [TEST] Introduce test-infrastructure-utils module and extract common test utilities here 2020-12-16 19:52:22 +03:00
Ilya Gorbunov b2b2629e79 Use new kotlin.io.path API in tests 2020-11-20 09:03:25 +03:00
Alexander Udalov a9ddf02556 Replace deprecated usages of max/min with maxOrNull/minOrNull 2020-08-25 20:33:59 +02:00
Alexander Udalov 9b94e073af Fix warnings related to OptIn/UseExperimental 2020-08-17 21:18:19 +02:00
Alexander Udalov 6e67e1e78d Replace appendln with appendLine in project 2020-06-11 13:01:30 +02:00
Ilya Chernikov 5e33612238 Extract interface from CompilerMessageLocation to ease extension
The CompilerMessageLocation is an implicit part of the binary daemon
protocol so changing it breaks compatibility with older daemons.
This change allows to extend location for non-daemon uses without
breaking the binary protocol.
2020-06-05 21:58:27 +02:00
Ilya Chernikov 574b917061 Remove new kotlin daemon from dist
hopefully temporarily, also see #KTI-173
2020-05-24 19:03:43 +02:00
Ilya Chernikov ec64869d39 Extract daemon tests to separate module 2020-04-21 16:49:11 +02:00