How can i retrieve cached dependency resolution results from gradles configuration cache


Looking at the document Improve the Performance of Gradle Builds

it says that dependency resolution results are cached by gradle when configuration cache is enabled.

Is there an api available that i can use to fetch the dependency resolution results from gradle configuration cache?

No, you cannot fetch anything from the configuration cache.
The configuration cache stores the tasks and their configuration in a serialized form and deserializes them if it can reuse the CC entry.
So if you for example have a ConfigurableFileCollection as input files property on a task and set it to some configuration, then the result of resolving the configuration is persisted to the CC as the paths to the resolved files.
That is what meant with that statement.

1 Like