<feed xmlns='http://www.w3.org/2005/Atom'>
<title>ydb/build/scripts/javac_daemon_client.py, branch main</title>
<subtitle>Mirror of YDB github repos</subtitle>
<id>https://code.mastervirt.ru/ydb/atom?h=main</id>
<link rel='self' href='https://code.mastervirt.ru/ydb/atom?h=main'/>
<link rel='alternate' type='text/html' href='https://code.mastervirt.ru/ydb/'/>
<updated>2026-07-02T20:37:44Z</updated>
<entry>
<title>conf var feature flag (__NO_UID__) + shallow root-based cache dir</title>
<updated>2026-07-02T20:37:44Z</updated>
<author>
<name>iniklyaev</name>
<email>iniklyaev@yandex-team.com</email>
</author>
<published>2026-07-02T19:47:17Z</published>
<link rel='alternate' type='text/html' href='https://code.mastervirt.ru/ydb/commit/?id=941084a7c1a64c6d8f63ec6d660ff690103083d2'/>
<id>urn:sha1:941084a7c1a64c6d8f63ec6d660ff690103083d2</id>
<content type='text'>
**Feature-flag the persistent javac/kotlinc daemon and relocate its runtime dir to SHALLOW_ROOT**

The javac/kotlinc daemon is now opt-in via `ya make -DYA_JAVAC_DAEMON` (default off). Toggling it does not change node UIDs; enabling/disabling the daemon never invalidates the build cache.
The daemon's runtime dir (jar \+ logs) moves from `/tmp` to ya's `$(SHALLOW_ROOT)` via `YA_JAVAC_DAEMON_HOME`, so it works in environments where `/tmp` is unwanted. The unix socket stays in `/tmp` because of the AF_UNIX path limit; the socket name gains the jar hash to distinguish daemon versions across protocol changes.

This code is LLM-generated.
commit_hash:179a98b265f6458d04a6bf6c7d02721c90cc355b
</content>
</entry>
<entry>
<title>Javac/kotlinc daemon [AI generated]</title>
<updated>2026-06-29T21:08:25Z</updated>
<author>
<name>iniklyaev</name>
<email>iniklyaev@yandex-team.com</email>
</author>
<published>2026-06-29T20:43:27Z</published>
<link rel='alternate' type='text/html' href='https://code.mastervirt.ru/ydb/commit/?id=66d0c52de24f9482c50a1efa2596824b7f635504'/>
<id>urn:sha1:66d0c52de24f9482c50a1efa2596824b7f635504</id>
<content type='text'>
**Persistent javac/kotlinc compilation daemon for `ya make` (opt-in)**

**Note:** the code in this PR was generated mostly by an LLM.

This PR adds an opt-in persistent compilation daemon that runs `javac` and `kotlinc` in-process inside a long-lived JVM, instead of spawning a fresh subprocess per build node. Each Java/Kotlin module today pays the full JVM \+ compiler startup cost (\~150–340 ms of startup, plus \~55 MB of kotlinc class-loading) on every node, which dominates the wall time of short compiles; amortizing that startup across all nodes in a build session yields measurable speedups (1.3x–3.7x CPU economy on the benchmarked targets, with zero correctness fallbacks or failed nodes).

The daemon (`devtools/buildstep_tools/javac_daemon`, a `JAVA_PROGRAM` built to a committed `JavacDaemon.jar`) listens on a Unix domain socket and runs both compilers concurrently; a thin Python client in the existing build scripts (`javac_daemon_client.py`, wired into `run_javac.py` / `compile_java.py` via `build/conf/java.conf`) decides per-node eligibility, routes launcher flags, selects/launches the right daemon instance, and **always falls back to a plain subprocess** on any doubt (old JDK, resource JVM flag, denied annotation processor, daemon error), so build correctness never depends on the daemon. The feature is **off by default** and activated only via `YA_JAVAC_DAEMON=1` passed to `ya make`; without it the build uses the existing subprocess path unchanged.

See `junk/iniklyaev/javac-daemon/DESIGN_javac_daemon.md` for the full design, flag-routing rules, fault-isolation model, and benchmark methodology.
commit_hash:f4e07c5bb51064e0bc24539348e01a85ff63a835
</content>
</entry>
</feed>
