IDEA-358562 Fix build output 'Starting Daemon' event using Daemon JVM criteria #2888
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Context
The
Daemon toolchain
was introduced in Gradle 8.8 and the motivation behind it and other technical details can be found on the public spec document. The implementation follows the agreed details on spec document and UI/UX document.Summary
Given a project using
Daemon JVM criteria
when starting a daemon the event is captured multiple times onGradleProgressListener
due to the fact that a newProgressLoggerFactory.newOperation
was nested on the originalStarting Gradle Daemon
as part of Daemon toolchain implementation. However, Gradle triggers always the parent event on completion resulting on the following:Before we had only
Connecting to Gradle Daemon
expecting only 2Starting Gradle Daemon
events, however, this isn't longer the case. For this reason, until a better way is provided by Gradle we are going to relay on the fact that latestStarting Gradle Daemon
is always proceeded byBuild
, representing his parent.Reported Gradle issue: gradle/gradle#31777
Tests
Overview