Through the Replication Add-on in Artifactory Pro, Artifactory allows replication of repositories to support development by different teams distributed over distant geographical sites. The benefits of replication are:
Two main methods of replication are supported:
Push replication is used to synchronize Local Repositories, and is implemented by the Artifactory server on the near end invoking a synchronization of artifacts to the far end.
There are two ways to invoke push replication:
Replication loop to be strictly avoided
Pull replication is invoked by a remote repository, and runs according to a defined schedule to synchronize repositories (local, remote or virtual) at regular intervals.
This provides a convenient way to proactively populate a remote cache, and is very useful when waiting for new artifacts to arrive on demand (when first requested) is not desirable due to network latency.
Pull replication runs as a scheduled task.
Scheduling and Configuring Replication
Using the UI
Replication is configured via the user interface as a scheduled task. Local repositories can be configured for push replication, and remote repositories can be configured for pull replication.
All replication messages are logged in the main Artifactory log file (
Configuring Push Replication
A push replication task for a Local Repository is configured in the Replication tab of the Edit Local Repository dialog as follows:
Configuring Pull Replication
Configuring Pull Replication for a Remote Repository is very similar to configuring Push Replication for a Local Repository. Please refer to Configuring Push Replication for details.
Replicating with REST API
Both Push and Pull Replication are supported by Artifactory's REST API. For details please refer to the following:
Watch the Screencast
To see the Replication in action you can watch the short demo screencast below.