Skip to content

Don't start a Gradle Daemon in CI workflows #99

Description

@Besi97

Context

The CI workflows (Build and Release) invoke Gradle via ./gradlew without --no-daemon. By default this starts a long-lived Gradle Daemon for every job, which is wasteful in ephemeral CI environments:

  • Each daemon JVM consumes memory (often 512MB+), and one is started per job/matrix entry.
  • The daemon is never reused across runs since runners are ephemeral, so it only adds startup cost and resource usage.
  • CI environments are single-build, so there is no benefit from daemon reuse.

Task

Ensure the Gradle invocations in the workflows do not start a daemon. Options:

  1. Add --no-daemon to each ./gradlew invocation in .github/workflows/github.yml and .github/workflows/release.yml.
  2. Alternatively, set org.gradle.daemon=false in a CI-specific gradle.properties (or via GRADLE_OPTS/environment in the workflow).

Note the gradle plugin build and example-server/client/client-kotlin builds run as separate ./gradlew -p ... invocations in the same job; ensure none of them spawn a daemon.

Acceptance criteria

  • No Gradle Daemon process is started during CI runs (verifiable via --info output or by checking the daemon registry).
  • Existing builds keep working without behavioral changes.

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions