We have an Android project with around 90 library modules. This question is about Dependency resolution. This phase mostly took around 10 - 20 seconds on some machines. Also, it looks like it took sometimes slightly more time with each build.
What is main contributor to longer times here? Is it mainly “implementation xyz”, “api xyz” in our modules in the dependency section in build.gradle files?
When looking here (https://docs.gradle.org/current/userguide/troubleshooting_dependency_resolution.html) we don’t use dynamic versions, we’re using “offline mode” etc. For example, should we avoid using “api xyz” at all cost? We’re using it for dependencies which are already downloaded from artifact repository as aar / jar (they will not be compiled again). Or any other suggestion what could be causing longer execution here except those mentioned in the documentation linked above?
We’re using the newest Gradle (5.6.2), AGP (3.5.1) and so on.
PS: Can’t / shouldn’t be some of the above cached when there is no change to both gradle and kotlin / java / resource files?