Remote repository how it works, pull replication with other Artifactory server and the ability to use only the cached artifacts

We would like to elaborate on the remote repository feature in Artifactory. Remote repositories in Artifactory serves as a caching proxy that the URL of the repository points to. To have the control over the storage of your hardware, the artifacts are being cached by the demand of the users. Therefore, it’s not being synced with the remote URL. With this said, if the remote repository is pointing to another Artifactory repository, you can set the pull replication feature of Artifactory to retrieve the artifacts from the remote Artifactory server and populate the remote repository cache. In this way, you can synchronize the repositories.

 

Regarding the second inquiry, to set the remote repository not to synchronize the data from the remote URL, you can achieve this by addressing to the remote repository with the -cache in the name. For example, if you are using the JCenter repository, named jcenter, that points to http://jcenter.bintray.com and you would like to use only the cached artifacts then please point the requests to jcenter-cache. Also, you can configure the repository not to check for new artifacts in the remote URL by configuring the repository to work in an offline mode. The offline mode declares this repository as not available for searching outside its cache and therefore the repository will only use the artifacts that have already been cached. This can be configured in the Artifactory UI → Admin tab → General → Repositories → Edit the required repository → check the Offline checkbox.

 

For further information regarding the remote repositories please click here.