Skip to content

[Enhancement]: apply Gradle best practices #10286

Open
@vlsi

Description

@vlsi

Module

Core

Proposal

Apply Gradle build practices so the build configuration does not take ~10 sec for every execution.

Currently, the project configuration takes ~11 seconds on Apple M1 which is very noticeable.
For instance, if I add a dependency to one of the modules, I have to wait for 10 seconds for the IDE to refresh. It does not have to be that long.

The slowness might be related to creating a lot of tasks eagerly "thanks" to old Groovy DSL code.

For instance, the code like the following always creates japicmp, and check tasks even in the case they will not be executed. The tasks are not required for IDE to pick up the updated project dependencies.

tasks.japicmp {
    dependsOn(tasks.shadowJar)
}
...

    project.tasks.check.dependsOn(japicmp)

PS. It would be nice to move to Kotlin DSL as per General Gradle Best Practices as well.

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions