Is the Repository Extensibility design change complete?


The release notes for Gradle 2.0 say ‘ArtifactRepositoryContainer.add(DependencyResolver) replaced with add(ArtifactRepository).’ This leads me to believe that the previously deprecated add(DependencyResolver) method now has an alternative way of adding customer repositories.

Prior to Grade 2, create a custom repository was easy, as the DependencyResolver interface completely specifies the methods that need to be implemented. However, ArtifactRepository simply has two methods - ‘setName’ and ‘getName’. Are we missing documentation that explains how to add a custom Repository?

I see the design document at which seems to indicate that custom repos are still not possible, but it also refers to DependencyResolver as being the current approach. This indicates that the document is now obsolete, but I can’t be sure.

So are custom repos supported by Gradle 2, or is this still under development? Is ‘add(ArtifactRepository)’ a complete replacement for ‘add(DependencyResolver)’ or not?

Thanks, Rajesh

There is a related thread on Gradle dev mailing list about adding support for P2 repositories that discusses the problem how to implement another repository. Check it out at!topic/gradle-dev/YQ2-V-RizQg